summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CPack/MAIN_COMPONENT.cmake
blob: 99c6caefd94a5b0e395e39aa20dfad7b53afe519 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
set(CPACK_RPM_COMPONENT_INSTALL "ON")

install(FILES CMakeLists.txt DESTINATION foo COMPONENT applications)
install(FILES CMakeLists.txt DESTINATION bar COMPONENT headers)
install(FILES CMakeLists.txt DESTINATION bas COMPONENT libs)

if(RunCMake_SUBTEST_SUFFIX STREQUAL "invalid")
  set(CPACK_RPM_MAIN_COMPONENT "")
else()
  set(CPACK_RPM_MAIN_COMPONENT "applications")
  set(CPACK_RPM_APPLICATIONS_FILE_NAME "RPM-DEFAULT")
endif()

set(CPACK_PACKAGE_NAME "main_component")