summaryrefslogtreecommitdiffstats
path: root/Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake
diff options
context:
space:
mode:
authorJoshua A Clayton <stillcompiling@gmail.com>2015-02-19 08:01:16 (GMT)
committerBrad King <brad.king@kitware.com>2015-02-23 15:48:36 (GMT)
commitf174b919d65d8aefbe8dec26e2b31c7525805f8d (patch)
tree335a9eda8e699a27456b930396dcd55ef0b3626c /Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake
parent3aa9f89dbb88d957a662effdbc284c95aef1a8a9 (diff)
downloadCMake-f174b919d65d8aefbe8dec26e2b31c7525805f8d.zip
CMake-f174b919d65d8aefbe8dec26e2b31c7525805f8d.tar.gz
CMake-f174b919d65d8aefbe8dec26e2b31c7525805f8d.tar.bz2
Tests: CpackRPM test component architecture
Test creating rpms of type "noarch", native, and "armv7hf"
Diffstat (limited to 'Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake')
-rw-r--r--Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake8
1 files changed, 8 insertions, 0 deletions
diff --git a/Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake b/Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake
index 68d846f..5be9d17 100644
--- a/Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake
+++ b/Tests/CPackComponentsForAll/RunCPackVerifyResult.cmake
@@ -161,21 +161,25 @@ if(CPackGen MATCHES "RPM")
set(check_file_match_expected_summary ".*${CPACK_RPM_libraries_PACKAGE_SUMMARY}.*")
set(check_file_match_expected_description ".*${CPACK_RPM_libraries_PACKAGE_DESCRIPTION}.*")
set(check_file_match_expected_relocation_path "Relocations : ${CPACK_PACKAGING_INSTALL_PREFIX} ${CPACK_PACKAGING_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}")
+ set(check_file_match_expected_architecture "Architecture: ${CPACK_RPM_applications_PACKAGE_ARCHITECTURE}")
set(spec_regex "*libraries*")
elseif(check_file_headers_match)
set(check_file_match_expected_summary ".*${CPACK_RPM_PACKAGE_SUMMARY}.*")
set(check_file_match_expected_description ".*${CPACK_COMPONENT_HEADERS_DESCRIPTION}.*")
set(check_file_match_expected_relocation_path "Relocations : ${CPACK_PACKAGING_INSTALL_PREFIX} ${CPACK_PACKAGING_INSTALL_PREFIX}/${CMAKE_INSTALL_INCLUDEDIR}")
+ set(check_file_match_expected_architecture "Architecture: ${CPACK_RPM_libraries_PACKAGE_ARCHITECTURE}")
set(spec_regex "*headers*")
elseif(check_file_applications_match)
set(check_file_match_expected_summary ".*${CPACK_RPM_PACKAGE_SUMMARY}.*")
set(check_file_match_expected_description ".*${CPACK_COMPONENT_APPLICATIONS_DESCRIPTION}.*")
set(check_file_match_expected_relocation_path "Relocations : ${CPACK_PACKAGING_INSTALL_PREFIX} ${CPACK_PACKAGING_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR}")
+ set(check_file_match_expected_architecture "Architecture: ${CPACK_RPM_headers_PACKAGE_ARCHITECTURE}")
set(spec_regex "*applications*")
elseif(check_file_Unspecified_match)
set(check_file_match_expected_summary ".*${CPACK_RPM_PACKAGE_SUMMARY}.*")
set(check_file_match_expected_description ".*DESCRIPTION.*")
set(check_file_match_expected_relocation_path "Relocations : ${CPACK_PACKAGING_INSTALL_PREFIX} ${CPACK_PACKAGING_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR}")
+ set(check_file_match_expected_architecture "Architecture: ${CPACK_RPM_Unspecified_PACKAGE_ARCHITECTURE}")
set(spec_regex "*Unspecified*")
else()
message(FATAL_ERROR "error: unexpected rpm package '${check_file}'")
@@ -204,6 +208,10 @@ if(CPackGen MATCHES "RPM")
message(FATAL_ERROR "error: '${check_file}' rpm package relocation path does not match expected value - regex '${check_file_match_expected_relocation_path}'; RPM output: '${check_file_content}'; generated spec file: '${spec_file_content}'")
endif()
+ string(REGEX MATCH ${check_file_match_expected_architecture} check_file_match_architecture ${check_file_content})
+ if (NOT check_file_match_architecture)
+ message(FATAL_ERROR "error: '${check_file}' Architecture does not match expected value - '${check_file_match_expected_architecture}'; RPM output: '${check_file_content}'; generated spec file: '${spec_file_content}'")
+ endif()
endforeach()
elseif(${CPackComponentWay} STREQUAL "IgnoreGroup")
endif()