diff options
author | hwspeedy <ns@bigbear.dk> | 2024-03-04 07:30:19 +0100 |
---|---|---|
committer | hwspeedy <ns@bigbear.dk> | 2024-03-04 07:30:19 +0100 |
commit | 16b5b72b1c2e66009c25b1fd06488bee64af5fb7 (patch) | |
tree | e77fe1fd6e6636ff0d275553a5a3b909204db1f6 /CMakeLists.txt | |
parent | 6d87ce5378d5727c2fa88669f61522f962a90a0d (diff) |
PACKAGING Fedora source packaging fixed
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 7c57bfba..10d75d58 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -120,6 +120,11 @@ if(DISTRO) string(REGEX REPLACE "[.].*" "" DISTRO_BUILD_VER ${DISTRO}) set(CPACK_PACKAGE_VERSION "${HARDINFO2_VERSION}-${DISTRO_BUILD_VER}") set(PACKAGE_DISTRO "${HARDINFO2_VERSION}-${DISTRO}") + if(${DISTRO_BUILD_VER} MATCHES "src") +# SET(CPACK_RPM_USER_BINARY_SPECFILE "hardinfo.spec") + set(CPACK_PACKAGE_VERSION "${HARDINFO2_VERSION}") + set(PACKAGE_DISTRO "${HARDINFO2_VERSION}") + endif() if(${HARDINFO2_GTK3}) else() message(FATAL_ERROR "Distro-Building not supported with GTK2!!") @@ -133,9 +138,9 @@ else() set(PACKAGE_MAINTAINER "hwspeedy <hardinfo2@bigbear.dk>") endif() #Put it together -string(REPLACE " " "_" CPACK_PACKAGE_FILE_NAME "hardinfo${PACKAGE_DELIMITER}${PACKAGE_DISTRO}${PACKAGE_ARCHITECTURE}") +string(REPLACE " " "${PACKAGE_DELIMITER}" CPACK_PACKAGE_FILE_NAME "hardinfo${PACKAGE_DELIMITER}${PACKAGE_DISTRO}${PACKAGE_ARCHITECTURE}") if(${RPM}) - string(REPLACE " " "_" CPACK_SOURCE_PACKAGE_FILE_NAME "hardinfo-${HARDINFO2_VERSION}") + string(REPLACE " " "-" CPACK_SOURCE_PACKAGE_FILE_NAME "hardinfo-${PACKAGE_DISTRO}") else() string(REPLACE " " "_" CPACK_SOURCE_PACKAGE_FILE_NAME "hardinfo-${HARDINFO2_VERSION}") endif() @@ -529,6 +534,7 @@ install(FILES pixmaps/hardinfo2.png SET(CPACK_PACKAGE_NAME "hardinfo") SET(CPACK_SOURCE_PACKAGE_NAME "hardinfo") SET(CPACK_PACKAGE_HOMEPAGE_URL "https://www.hardinfo2.org") +set(CPACK_PACKAGING_INSTALL_PREFIX "/usr") if(${RPM}) SET(CPACK_SOURCE_IGNORE_FILES "/build/;/.git/;/.github/;.gitignore;.gitmodules;*.po.old;*~;*.mo;") SET(CPACK_SOURCE_GENERATOR "RPM;TGZ") @@ -542,11 +548,14 @@ else() endif() #RPM +SET(CPACK_RPM_PACKAGE_DEBUG 1) SET(CPACK_RPM_PACKAGE_MAINTAINER ${PACKAGE_MAINTAINER}) -SET(CPACK_RPM_PACKAGE_DESCRIPTION "Hardinfo2 is a small application that displays information about your hardware and operating system. It has online benchmarking to check your machine performance against other machines.") +SET(CPACK_RPM_PACKAGE_DESCRIPTION "Hardinfo2 - System Information and Benchmark") SET(CPACK_RPM_PACKAGE_RECOMMENDS "sysbench, udisks2, mesa-utils, lsscsi, lm-sensors, xdg-utils, iperf3") SET(CPACK_RPM_PACKAGE_LICENSE "GPL2+") SET(CPACK_RPM_PACKAGE_HOMEPAGE "https://github.com/hardinfo2/hardinfo2") +SET(CPACK_RPM_PACKAGE_URL "https://www.hardinfo2.org") +SET(CPACK_RPM_SOURCE_PKG_BUILD_PARAMS "-DDISTRO=1") if(HARDINFO2_LIBSOUP3) SET(PACKAGE_LS "libsoup (>=3.0)") else() @@ -561,7 +570,8 @@ SET(CPACK_RPM_PACKAGE_DEPENDS "libjson-glib-1.0-0, zlib, ${PACKAGE_LS}, ${PACKAG #DEB SET(CPACK_DEBIAN_PACKAGE_MAINTAINER ${PACKAGE_MAINTAINER}) -SET(CPACK_DEBIAN_PACKAGE_DESCRIPTION "Hardinfo2 is a small application that displays information about your hardware and operating system. It has online benchmarking to check your machine performance against other machines.") +SET(CPACK_DEBIAN_PACKAGE_DESCRIPTION "Hardinfo2 is a small application that displays information about your +hardware and operating system. It has online benchmarking to check your machine performance against other machines.") SET(CPACK_DEBIAN_PACKAGE_RECOMMENDS "sysbench, udisks2, mesa-utils, lsscsi, lm-sensors, xdg-utils, iperf3") SET(CPACK_DEBIAN_PACKAGE_HOMEPAGE "https://github.com/hardinfo2/hardinfo2") if(HARDINFO2_LIBSOUP3) |