1 cmake_minimum_required (VERSION 2.6)
2 PROJECT(SystemInformation)
4 INCLUDE_DIRECTORIES("This does not exists")
5 GET_DIRECTORY_PROPERTY(incl INCLUDE_DIRECTORIES)
6 SET_DIRECTORY_PROPERTIES(PROPERTIES INCLUDE_DIRECTORIES "${SystemInformation_BINARY_DIR};${SystemInformation_SOURCE_DIR}")
8 MESSAGE("To prevent CTest from stripping output, you have to display: CTEST_FULL_OUTPUT")
11 CONFIGURE_FILE(${SystemInformation_SOURCE_DIR}/SystemInformation.in
12 ${SystemInformation_BINARY_DIR}/SystemInformation.out)
13 CONFIGURE_FILE(${SystemInformation_SOURCE_DIR}/DumpInformation.h.in
14 ${SystemInformation_BINARY_DIR}/DumpInformation.h)
15 ADD_EXECUTABLE(SystemInformation DumpInformation.cxx)
23 FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/AllVariables.txt "")
24 GET_CMAKE_PROPERTY(res VARIABLES)
26 FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/AllVariables.txt
27 "${var} \"${${var}}\"\n")
28 ENDFOREACH(var ${res})
30 FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/AllCommands.txt "")
31 GET_CMAKE_PROPERTY(res COMMANDS)
33 FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/AllCommands.txt
35 ENDFOREACH(var ${res})
37 FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/AllMacros.txt "")
38 GET_CMAKE_PROPERTY(res MACROS)
40 FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/AllMacros.txt
42 ENDFOREACH(var ${res})
44 FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/OtherProperties.txt "")
45 GET_DIRECTORY_PROPERTY(res INCLUDE_DIRECTORIES)
47 FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/OtherProperties.txt
48 "INCLUDE_DIRECTORY: ${var}\n")
51 GET_DIRECTORY_PROPERTY(res LINK_DIRECTORIES)
53 FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/OtherProperties.txt
54 "LINK_DIRECTORIES: ${var}\n")
57 GET_DIRECTORY_PROPERTY(res INCLUDE_REGULAR_EXPRESSION)
58 FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/OtherProperties.txt
59 "INCLUDE_REGULAR_EXPRESSION: ${res}\n")