diff options
author | Eric NOULARD <eric.noulard@gmail.com> | 2011-01-30 12:11:25 (GMT) |
---|---|---|
committer | Eric NOULARD <eric.noulard@gmail.com> | 2011-01-30 12:11:25 (GMT) |
commit | 92ced20fa13cd2b4ed45a80d265a590d2291f8ee (patch) | |
tree | 78ab255542bb412764e131b59aa0973eaf9042cf /Tests/CMakeLists.txt | |
parent | 04d4afbfa863bc43ab4d597b0b1a64f9a86c9ba2 (diff) | |
download | CMake-92ced20fa13cd2b4ed45a80d265a590d2291f8ee.zip CMake-92ced20fa13cd2b4ed45a80d265a590d2291f8ee.tar.gz CMake-92ced20fa13cd2b4ed45a80d265a590d2291f8ee.tar.bz2 |
CPack Tests the different ways of packaging components
Diffstat (limited to 'Tests/CMakeLists.txt')
-rw-r--r-- | Tests/CMakeLists.txt | 56 |
1 files changed, 33 insertions, 23 deletions
diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt index cbca02d..5f0bf25 100644 --- a/Tests/CMakeLists.txt +++ b/Tests/CMakeLists.txt @@ -563,30 +563,40 @@ ${CMake_BINARY_DIR}/bin/cmake -DVERSION=master -P ${CMake_SOURCE_DIR}/Utilities/ IF(CTEST_RUN_CPackComponentsForAll) set(CPackComponentsForAll_EXTRA_OPTIONS) - - set(CPackRun_CPackGen "-DCPackGen=ZIP") set(CPackRun_CPackCommand "-DCPackCommand=${CMAKE_CPACK_COMMAND}") - set(CPackRun_CPackComponentWay "-DCPackComponentWay=default") - - ADD_TEST(CPackComponentsForAll-ZIP-default ${CMAKE_CTEST_COMMAND} - --build-and-test - "${CMake_SOURCE_DIR}/Tests/CPackComponentsForAll" - "${CMake_BINARY_DIR}/Tests/CPackComponentsForAll/buildZIP-NoComponent" - --build-generator ${CMAKE_TEST_GENERATOR} - --build-project CPackComponentsForAll - --build-makeprogram ${CMAKE_TEST_MAKEPROGRAM} - --build-options - -DCPACK_BINARY_ZIP:BOOL=ON - ${CPackComponentsForAll_EXTRA_OPTIONS} - --graphviz=CPackComponentsForAll.dot - --test-command ${CMAKE_CMAKE_COMMAND} - "-DCPackComponentsForAll_BINARY_DIR:PATH=${CMake_BINARY_DIR}/Tests/CPackComponentsForAll/buildZIP-NoComponent" - "${CPackRun_CPackCommand}" - "${CPackRun_CPackGen}" - "${CPackRun_CPackComponentWay}" - -P "${CMake_SOURCE_DIR}/Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake") - - LIST(APPEND TEST_BUILD_DIRS "${CMake_BINARY_DIR}/Tests/CPackComponentsForAll") + # set up list of CPack generators + list(APPEND GENLST "ZIP") + # set up list of component packaging ways + list(APPEND CWAYLST "default") + list(APPEND CWAYLST "OnePackPerGroup") + list(APPEND CWAYLST "IgnoreGroup") + list(APPEND CWAYLST "AllInOne") + list(APPEND CWAYLST "AllGroupsInOne") + foreach(CPackGen IN LISTS GENLST) + set(CPackRun_CPackGen "-DCPackGen=${CPackGen}") + foreach(CPackComponentWay IN LISTS CWAYLST) + set(CPackRun_CPackComponentWay "-DCPackComponentWay=${CPackComponentWay}") + ADD_TEST(CPackComponentsForAll-${CPackGen}-${CPackComponentWay} ${CMAKE_CTEST_COMMAND} + --build-and-test + "${CMake_SOURCE_DIR}/Tests/CPackComponentsForAll" + "${CMake_BINARY_DIR}/Tests/CPackComponentsForAll/build${CPackGen}-${CPackComponentWay}" + --build-generator ${CMAKE_TEST_GENERATOR} + --build-project CPackComponentsForAll + --build-makeprogram ${CMAKE_TEST_MAKEPROGRAM} + --build-options + -DCPACK_BINARY_${CPackGen}:BOOL=ON + ${CPackRun_CPackComponentWay} + ${CPackComponentsForAll_EXTRA_OPTIONS} + --graphviz=CPackComponentsForAll.dot + --test-command ${CMAKE_CMAKE_COMMAND} + "-DCPackComponentsForAll_BINARY_DIR:PATH=${CMake_BINARY_DIR}/Tests/CPackComponentsForAll/build${CPackGen}-${CPackComponentWay}" + "${CPackRun_CPackCommand}" + "${CPackRun_CPackGen}" + "${CPackRun_CPackComponentWay}" + -P "${CMake_SOURCE_DIR}/Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake") + LIST(APPEND TEST_BUILD_DIRS "${CMake_BINARY_DIR}/Tests/CPackComponentsForAll/build${CPackGen}-${CPackComponentWay}") + endforeach(CPackComponentWay) + endforeach(CPackGen) ENDIF(CTEST_RUN_CPackComponentsForAll) # By default, turn this test off (because it takes a long time...) |