diff options
author | Andy Cedilnik <andy.cedilnik@kitware.com> | 2003-08-04 00:47:44 (GMT) |
---|---|---|
committer | Andy Cedilnik <andy.cedilnik@kitware.com> | 2003-08-04 00:47:44 (GMT) |
commit | c7f1198a0062a24edf3166e5f4cfcdcbb8b556f7 (patch) | |
tree | 21c76e21802cf818682bdb187b2152f7e705f16f /Tests | |
parent | 32bfe66b5d261bfc6c9f43f045f56651b8f012ea (diff) | |
download | CMake-c7f1198a0062a24edf3166e5f4cfcdcbb8b556f7.zip CMake-c7f1198a0062a24edf3166e5f4cfcdcbb8b556f7.tar.gz CMake-c7f1198a0062a24edf3166e5f4cfcdcbb8b556f7.tar.bz2 |
ENH: Add accessor for the list of commands
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/SystemInformation/CMakeLists.txt | 20 | ||||
-rw-r--r-- | Tests/SystemInformation/DumpInformation.cxx | 1 |
2 files changed, 14 insertions, 7 deletions
diff --git a/Tests/SystemInformation/CMakeLists.txt b/Tests/SystemInformation/CMakeLists.txt index 8fbba95..93d93c6 100644 --- a/Tests/SystemInformation/CMakeLists.txt +++ b/Tests/SystemInformation/CMakeLists.txt @@ -6,11 +6,17 @@ CONFIGURE_FILE(${DumpInformation_SOURCE_DIR}/DumpInformation.h.in ${DumpInformation_BINARY_DIR}/DumpInformation.h) ADD_EXECUTABLE(DumpInformation DumpInformation.cxx) -WRITE_FILE(${DumpInformation_BINARY_DIR}/AllVariables.txt "") -GET_CMAKE_PROPERTY(VARS VARIABLES) -FOREACH(var ${VARS}) - WRITE_FILE(${DumpInformation_BINARY_DIR}/AllVariables.txt - "${var} \"${${var}}\"" APPEND) - #MESSAGE(STATUS "Variable ${var} \"${${var}}\"") -ENDFOREACH(var ${VARS}) +FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/AllVariables.txt "") +GET_CMAKE_PROPERTY(res VARIABLES) +FOREACH(var ${res}) + FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/AllVariables.txt + "${var} \"${${var}}\"\n") +ENDFOREACH(var ${res}) + +FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/AllCommands.txt "") +GET_CMAKE_PROPERTY(res COMMANDS) +FOREACH(var ${res}) + FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/AllCommands.txt + "${var}\n") +ENDFOREACH(var ${res}) diff --git a/Tests/SystemInformation/DumpInformation.cxx b/Tests/SystemInformation/DumpInformation.cxx index 86f4698..30ae400 100644 --- a/Tests/SystemInformation/DumpInformation.cxx +++ b/Tests/SystemInformation/DumpInformation.cxx @@ -53,6 +53,7 @@ int main(int,char *[]) { DumpInformation_BINARY_DIR "/SystemInformation.out", DumpInformation_BINARY_DIR "/AllVariables.txt", + DumpInformation_BINARY_DIR "/AllCommands.txt", DumpInformation_BINARY_DIR "/../../Source/cmConfigure.h", DumpInformation_BINARY_DIR "/../../CMakeCache.txt", DumpInformation_BINARY_DIR "/../../CMakeOutput.log", |