mirror of
https://github.com/gflags/gflags.git
synced 2025-04-05 05:25:04 +00:00
Use dpkg --print-architecture also for RPM generator.
This commit is contained in:
parent
e8890f274a
commit
a49a656f1e
1 changed files with 10 additions and 0 deletions
|
@ -37,6 +37,7 @@ elseif (CPACK_GENERATOR MATCHES "DEB")
|
|||
if (NOT RV EQUAL 0)
|
||||
set (CPACK_DEBIAN_PACKAGE_ARCHITECTURE i386)
|
||||
endif ()
|
||||
|
||||
set (CPACK_DEBIAN_PACKAGE_DEPENDS)
|
||||
set (CPACK_DEBIAN_PACKAGE_SECTION "devel")
|
||||
set (CPACK_DEBIAN_PACKAGE_PRIORITY "optional")
|
||||
|
@ -47,6 +48,15 @@ elseif (CPACK_GENERATOR MATCHES "DEB")
|
|||
# RPM package
|
||||
elseif (CPACK_GENERATOR MATCHES "RPM")
|
||||
|
||||
execute_process (
|
||||
COMMAND dpkg --print-architecture
|
||||
RESULT_VARIABLE RV
|
||||
OUTPUT_VARIABLE CPACK_RPM_PACKAGE_ARCHITECTURE
|
||||
)
|
||||
if (NOT RV EQUAL 0)
|
||||
set (CPACK_RPM_PACKAGE_ARCHITECTURE i386)
|
||||
endif ()
|
||||
|
||||
set (CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}")
|
||||
if (DEVEL)
|
||||
set (CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_FILE_NAME}-devel")
|
||||
|
|
Loading…
Add table
Reference in a new issue