From bdc7d279989c7f1d9a3daa351a20679b76cb5fb5 Mon Sep 17 00:00:00 2001 From: Jari Karppinen Date: Sat, 2 Sep 2017 12:04:20 +0300 Subject: [PATCH] Update CMakeLists.txt (#168) * Update CMakeLists.txt This just reuses the default package description for RPM package as well (one would expect this to be the default, but doesn't seem to be the case with cmake 3.9.1 at least). * Update CMakeLists.txt This prevents cryfs RPM for owning filesystem directories which was causing installation error. * Update README.md Same instructions apply for building .rpm package. --- README.md | 8 ++++---- cpack/CMakeLists.txt | 2 ++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 633f8d37..846b4e50 100644 --- a/README.md +++ b/README.md @@ -133,12 +133,12 @@ On most systems, CMake should find the libraries automatically. However, that do cmake .. -DCMAKE_C_FLAGS="-I/path/to/openssl/include" -Creating .deb packages ----------------------- +Creating .deb and .rpm packages +------------------------------- -There are additional requirements if you want to create .deb packages. They are: +There are additional requirements if you want to create packages. They are: - CMake version >= 3.3 - - (optional) rpmbuild + - rpmbuild for creating .rpm package 1. Clone repository diff --git a/cpack/CMakeLists.txt b/cpack/CMakeLists.txt index 06958bc1..8aba91e3 100644 --- a/cpack/CMakeLists.txt +++ b/cpack/CMakeLists.txt @@ -44,6 +44,8 @@ if(BUILDTYPE MATCHES RELEASE AND NOT BUILD_TESTING) set(CPACK_DEBIAN_PACKAGE_HOMEPAGE "https://www.cryfs.org") set(CPACK_RPM_PACKAGE_LICENSE "LGPLv3") + set(CPACK_RPM_PACKAGE_DESCRIPTION ${CPACK_PACKAGE_DESCRIPTION}) + set(CPACK_RPM_EXCLUDE_FROM_AUTO_FILELIST_ADDITION "/usr/bin;/usr/share/man;/usr/share/man/man1") set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_SOURCE_DIR}/debfiles/postinst;${CMAKE_CURRENT_SOURCE_DIR}/debfiles/postrm") include(CPack)