From 624dfb349dc582b54479f96b3866a63f94c4a759 Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Sun, 9 Jun 2024 07:08:43 +0200 Subject: [PATCH] [Documentation enhancement] Stop packing useless documentaion files, start packing useful documentation file --- docs.patch | 21 +++++++++++++++++++++ galera.spec | 6 +++--- 2 files changed, 24 insertions(+), 3 deletions(-) create mode 100644 docs.patch diff --git a/docs.patch b/docs.patch new file mode 100644 index 0000000..ecaa42c --- /dev/null +++ b/docs.patch @@ -0,0 +1,21 @@ +The CMake prepares file AUTHORS for packing. +It only contains one line, and isn't packed in any upstream-produced packagess. +I don't find it useful and since upstream doesn't pack it either, stop packing it here. + +The README file contains infromation on how to build the project from sources, and thus isn't useful for the end users. + +On the other hand, the README-MySQL isn't prepared for packing by CMake, but contains useful information about the software usage and it is package in upstream-produced packages. + +--- galera-26.4.18/CMakeLists.txt 2024-06-09 04:54:56.281408893 +0200 ++++ galera-26.4.18/CMakeLists.txt_patched 2024-06-09 06:52:58.093217968 +0200 +@@ -118,9 +118,8 @@ endif() + + if (NOT ${CMAKE_SYSTEM_NAME} MATCHES ".*BSD") + install(FILES +- ${PROJECT_SOURCE_DIR}/AUTHORS + ${PROJECT_SOURCE_DIR}/COPYING +- ${PROJECT_SOURCE_DIR}/README ++ ${PROJECT_SOURCE_DIR}/scripts/packages/README-MySQL + DESTINATION ${INSTALL_DOCDIR} ) + install(FILES ${PROJECT_SOURCE_DIR}/asio/LICENSE_1_0.txt + DESTINATION ${INSTALL_DOCDIR} diff --git a/galera.spec b/galera.spec index 22c0591..7fb03e0 100644 --- a/galera.spec +++ b/galera.spec @@ -19,6 +19,7 @@ Source1: garbd.service Source2: garbd-wrapper Patch0: cmake_paths.patch +Patch1: docs.patch BuildRequires: boost-devel check-devel openssl-devel cmake systemd gcc-c++ asio-devel Requires(pre): /usr/sbin/useradd @@ -38,6 +39,7 @@ description of Galera replication engine see https://www.galeracluster.com web. %prep %setup -q %patch -P0 -p1 +%patch -P1 -p1 %build %{set_build_flags} @@ -151,11 +153,9 @@ install -D -m 755 %{SOURCE2} %{buildroot}%{_sbindir}/garbd-wrapper %{_libdir}/galera/libgalera_smm.so -%doc %{_docdir}/galera/AUTHORS %doc %{_docdir}/galera/COPYING %doc %{_docdir}/galera/LICENSE.asio -%doc %{_docdir}/galera/README -#%doc %{_docdir}/galera/README-MySQL +%doc %{_docdir}/galera/README-MySQL %changelog