Test printing origin of include dirs from tll().

This commit is contained in:
Stephen Kelly 2013-02-05 10:24:39 +01:00
parent 7c0ec75cfa
commit 5f926a5802
2 changed files with 17 additions and 4 deletions

View File

@ -23,13 +23,21 @@ CMake Debug Log at DebugIncludes.cmake:18 \(include_directories\):
Call Stack \(most recent call first\):
CMakeLists.txt:3 \(include\)
+
CMake Debug Log at DebugIncludes.cmake:25 \(set_property\):
CMake Debug Log at DebugIncludes.cmake:26 \(target_link_libraries\):
Used includes for target lll:
\* .*/Tests/RunCMake/include_directories/five
\* .*/Tests/RunCMake/include_directories/six
Call Stack \(most recent call first\):
DebugIncludes.cmake:35 \(some_macro\)
DebugIncludes.cmake:38 \(some_function\)
CMakeLists.txt:3 \(include\)
+
CMake Debug Log at DebugIncludes.cmake:29 \(set_property\):
Used includes for target lll:
\* .*/Tests/RunCMake/include_directories/six
\* .*/Tests/RunCMake/include_directories/seven
Call Stack \(most recent call first\):
DebugIncludes.cmake:40 \(some_macro\)
DebugIncludes.cmake:43 \(some_function\)
CMakeLists.txt:3 \(include\)

View File

@ -21,6 +21,10 @@ include_directories(
"${CMAKE_CURRENT_SOURCE_DIR}/four"
)
add_library(foo "${CMAKE_CURRENT_BINARY_DIR}/DebugIncludes.cpp")
target_include_directories(foo INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}/five")
target_link_libraries(lll foo)
macro(some_macro)
set_property(TARGET lll APPEND PROPERTY
INCLUDE_DIRECTORIES "${CMAKE_CURRENT_SOURCE_DIR}/one"
@ -28,6 +32,7 @@ macro(some_macro)
"${CMAKE_CURRENT_SOURCE_DIR}/four"
"${CMAKE_CURRENT_SOURCE_DIR}/five"
"${CMAKE_CURRENT_SOURCE_DIR}/six"
"${CMAKE_CURRENT_SOURCE_DIR}/seven"
)
endmacro()