From 5432e578acddb7216c1f61cf2681727c17e36de6 Mon Sep 17 00:00:00 2001 From: Xiao-Long Chen Date: Tue, 16 Sep 2014 00:11:20 -0400 Subject: [PATCH] Fix incorrect CMake test directory when building as a subproject This is an extension of e800985adbb0820c5692ea016b3a8499d69a73dc --- cat/test/CMakeLists.txt | 2 +- cpio/test/CMakeLists.txt | 2 +- tar/test/CMakeLists.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cat/test/CMakeLists.txt b/cat/test/CMakeLists.txt index ebb702ad8..bac00854c 100644 --- a/cat/test/CMakeLists.txt +++ b/cat/test/CMakeLists.txt @@ -53,7 +53,7 @@ IF(ENABLE_CAT AND ENABLE_TEST) INCLUDE(${CMAKE_CURRENT_BINARY_DIR}/list.h) INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}) - INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/test_utils) + INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/test_utils) # Experimental new test handling ADD_CUSTOM_TARGET(run_bsdcat_test diff --git a/cpio/test/CMakeLists.txt b/cpio/test/CMakeLists.txt index d4f93bb0c..ee900cdac 100644 --- a/cpio/test/CMakeLists.txt +++ b/cpio/test/CMakeLists.txt @@ -84,7 +84,7 @@ IF(ENABLE_CPIO AND ENABLE_TEST) INCLUDE(${CMAKE_CURRENT_BINARY_DIR}/list.h) INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}) - INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/test_utils) + INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/test_utils) # Experimental new test handling ADD_CUSTOM_TARGET(run_bsdcpio_test diff --git a/tar/test/CMakeLists.txt b/tar/test/CMakeLists.txt index f82ea5767..2f46727c8 100644 --- a/tar/test/CMakeLists.txt +++ b/tar/test/CMakeLists.txt @@ -92,7 +92,7 @@ IF(ENABLE_TAR AND ENABLE_TEST) INCLUDE(${CMAKE_CURRENT_BINARY_DIR}/list.h) INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}) - INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/test_utils) + INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/test_utils) # Experimental new test handling ADD_CUSTOM_TARGET(run_bsdtar_test -- 2.47.2