View Issue Details [ Jump to Notes ] | [ Print ] |
ID | Project | Category | View Status | Date Submitted | Last Update |
0015169 | CMake | CPack | public | 2014-09-22 15:36 | 2015-03-20 16:54 |
|
Reporter | Sam Hartsfield | |
Assigned To | Domen Vrankar | |
Priority | normal | Severity | minor | Reproducibility | always |
Status | closed | Resolution | fixed | |
Platform | Linux | OS | Linux | OS Version | |
Product Version | CMake 3.0.2 | |
Target Version | | Fixed in Version | CMake 3.3 | |
|
Summary | 0015169: CPackRPM: component-specific settings "fall through" to next component |
Description | When component support is enabled in CPackRPM, component-specific settings get applied not only to the specified component, but also to any subsequent components. Some of these settings can be unset for the latter components, but some cannot (e.g. CPACK_RPM_USER_BINARY_SPECFILE). |
Steps To Reproduce | See attached example. For spec.in file, use a standard template (cpack -D CPACK_RPM_GENERATE_USER_BINARY_SPECFILE_TEMPLATE=1 -G RPM). |
Tags | No tags attached. |
|
Attached Files | CMakeLists.txt [^] (859 bytes) 2014-09-22 15:36 [Show Content] [Hide Content]cmake_minimum_required(VERSION 2.8.12.2)
project(cpackbug)
file(WRITE a.txt "A")
file(WRITE b.txt "B")
file(WRITE c.txt "C")
install(FILES a.txt DESTINATION foo COMPONENT a)
install(FILES b.txt DESTINATION foo COMPONENT b)
install(FILES c.txt DESTINATION foo COMPONENT c)
set(CPACK_GENERATOR RPM)
set(CPACK_RPM_COMPONENT_INSTALL ON)
set(CPACK_RPM_a_PACKAGE_REQUIRES "foo")
set(CPACK_RPM_b_PACKAGE_REQUIRES "bar")
# If requirements for 'c' are unset, it gets 'bar'.
# This is not a big problem, because we can set it to
# an empty string to override.
#set(CPACK_RPM_c_PACKAGE_REQUIRES "")
# Both B and C will use this user specfile template. Setting
# the template for C to an empty string *does not* override.
set(CPACK_RPM_b_USER_BINARY_SPECFILE
${CMAKE_CURRENT_SOURCE_DIR}/cpackbug.spec.in)
set(CPACK_RPM_c_USER_BINARY_SPECFILE "")
include(CPack)
|
|