Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package galera-4 for openSUSE:Factory 
checked in at 2022-02-03 23:15:45
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/galera-4 (Old)
 and      /work/SRC/openSUSE:Factory/.galera-4.new.1898 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "galera-4"

Thu Feb  3 23:15:45 2022 rev:3 rq:950692 version:26.4.10

Changes:
--------
--- /work/SRC/openSUSE:Factory/galera-4/galera-4.changes        2022-01-08 
23:23:00.602201807 +0100
+++ /work/SRC/openSUSE:Factory/.galera-4.new.1898/galera-4.changes      
2022-02-03 23:15:57.876826505 +0100
@@ -1,0 +2,7 @@
+Wed Jan 26 15:30:10 UTC 2022 - Danilo Spinella <danilo.spine...@suse.com>
+
+- Use cmake by default to fix build with GCC 12, fixes bsc#1194790
+  * Add fix-cmake-install.patch
+- Add fix-cmake-build.patch to fix cmake build, fixes bsc#1194827
+
+-------------------------------------------------------------------

New:
----
  fix-cmake-build.patch
  fix-cmake-install.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ galera-4.spec ++++++
--- /var/tmp/diff_new_pack.wFf4DI/_old  2022-02-03 23:15:58.400822928 +0100
+++ /var/tmp/diff_new_pack.wFf4DI/_new  2022-02-03 23:15:58.404822901 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package galera-4
 #
-# Copyright (c) 2021 SUSE LLC
+# Copyright (c) 2022 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,6 @@
 
 
 %define copyright Copyright 2007-2015 Codership Oy. All rights reserved. Use 
is subject to license terms under GPLv2 license.
-%define libs %{_libdir}/%{name}
 %define docs %{_docdir}/%{name}
 %define homedir   %{_localstatedir}/lib/garb
 %define galeradir %{_localstatedir}/lib/galera
@@ -25,7 +24,6 @@
 %if ! %{defined _fillupdir}
   %define _fillupdir %{_localstatedir}/adm/fillup-templates
 %endif
-%bcond_with cmake
 Name:           galera-4
 Version:        26.4.10
 Release:        0
@@ -37,6 +35,10 @@
 Source1:        
http://releases.galeracluster.com/galera-4/source/%{name}-%{version}.tar.gz.asc
 Source2:        garb-user.conf
 Patch0:         galera-3-25.3.10_fix_startup_scripts.patch
+# PATCH-FIX-UPSTREAM danilo.spine...@suse.com
+# https://github.com/codership/galera/issues/611
+Patch1:         fix-cmake-build.patch
+Patch2:         fix-cmake-install.patch
 BuildRequires:  boost-devel
 BuildRequires:  check-devel
 BuildRequires:  gcc-c++
@@ -44,17 +46,15 @@
 # for fileownership of galeradir
 BuildRequires:  mariadb >= %{mariadb_version}
 BuildRequires:  pkgconfig
-BuildRequires:  pkgconfig(systemd)
 BuildRequires:  sysuser-tools
+BuildRequires:  pkgconfig(systemd)
 Requires:       %{name}-wsrep-provider
 Conflicts:      galera-3
 %if 0%{?suse_version} >= 1500
 BuildRequires:  libboost_program_options-devel
 BuildRequires:  libboost_system-devel
 %endif
-%if %{with cmake}
 BuildRequires:  cmake
-%endif
 # for fileownership of galeradir
 %if %{with split_package}
 BuildRequires:  mysql-server
@@ -67,9 +67,6 @@
 %if %{defined fedora}
 BuildRequires:  python
 %endif
-%if %{without cmake}
-BuildRequires:  scons
-%endif
 
 %description
 Galera is a fast synchronous multimaster wsrep provider (replication engine)
@@ -112,32 +109,19 @@
 export CFLAGS="$CFLAGS -Wno-implicit-fallthrough"
 export CXXFLAGS="$CXXFLAGS -Wno-implicit-fallthrough"
 %endif
-%if %{with cmake}
-%cmake
+%cmake -DGALERA_SYSTEMD_UNITDIR:PATH=%{_unitdir} \
+       -DCMAKE_INSTALL_DOCDIR:PATH=%{_datarootdir}/doc/packages/%{name}
 %cmake_build
-%else
-scons %{?_smp_mflags} deterministic_tests=1 version=%{version} ssl=1 
system_asio=1 boost_pool=1
-%endif
 %sysusers_generate_pre %{SOURCE2} garb garb-user.conf
 
 %install
-install -D -m 644 garb/files/garb.service %{buildroot}%{_unitdir}/garb.service
-install -D -m 755 garb/files/garb-systemd %{buildroot}%{_bindir}/garb-systemd
+%cmake_install
 mkdir -p %{buildroot}%{_sysusersdir}
 install -D -m 0644 %{SOURCE2} %{buildroot}%{_sysusersdir}/
 
-install -D -m 644 garb/files/garb.cnf        
%{buildroot}%{_fillupdir}/sysconfig.garb
-
-install -D -m 755 garb/garbd                 %{buildroot}%{_bindir}/garbd
-install -D -m 755 libgalera_smm.so           
%{buildroot}%{libs}/libgalera_smm.so
+mkdir -p %{buildroot}%{_fillupdir}
+mv %{buildroot}%{_prefix}/etc/garb.cnf %{buildroot}%{_fillupdir}/sysconfig.garb
 
-install -d %{buildroot}%{docs}
-install -m 644 COPYING                       %{buildroot}%{docs}/COPYING
-install -m 644 asio/LICENSE_1_0.txt          %{buildroot}%{docs}/LICENSE.asio
-install -m 644 scripts/packages/README       %{buildroot}%{docs}/README
-install -m 644 scripts/packages/README-MySQL %{buildroot}%{docs}/README-MySQL
-
-install -D -m 644 man/garbd.8                
%{buildroot}%{_mandir}/man8/garbd.8
 install -D -d -m 0750 %{buildroot}%{homedir} %{buildroot}%{galeradir}
 install -D -d -m 0755 %{buildroot}%{_sysconfdir}/my.cnf.d/
 cat > %{buildroot}%{_sysconfdir}/my.cnf.d/51-%{name}-wsrep-provider.cnf <<EOF
@@ -145,7 +129,7 @@
 # For configuring galera please use 50-galera.cnf or another file
 # This file is only here to set the proper path to the wsrep_provider library
 [mysqld]
-wsrep_provider=%{libs}/libgalera_smm.so
+wsrep_provider=%{_libdir}/libgalera_smm.so
 EOF
 
 %files
@@ -154,7 +138,7 @@
 # /common
 # garb
 %{_unitdir}/garb.service
-%{_bindir}/garb-systemd
+%{_libexecdir}/garb-systemd
 %config(noreplace,missingok) %{_fillupdir}/sysconfig.garb
 %{_bindir}/garbd
 #
@@ -170,12 +154,10 @@
 # plugin
 
 %files wsrep-provider
-%dir %{libs}
-%{libs}/libgalera_smm.so
+%{_libdir}/libgalera_smm.so
 %config %{_sysconfdir}/my.cnf.d/51-%{name}-wsrep-provider.cnf
 
-%pre -f garb.pre
-
+%pre
 %service_add_pre garb.service
 
 %preun

++++++ fix-cmake-build.patch ++++++
diff --git a/galera/src/CMakeLists.txt b/galera/src/CMakeLists.txt
index cc7775d7..5c8189d3 100644
--- a/galera/src/CMakeLists.txt
+++ b/galera/src/CMakeLists.txt
@@ -2,7 +2,7 @@
 # Copyright (C) 2020 Codership Oy <i...@codership.com>
 #
 
-add_library(galera
+add_library(galera STATIC
   mapped_buffer.cpp
   write_set.cpp
   data_set.cpp
@@ -46,7 +46,7 @@ else()
   target_link_libraries(galera gcs)
 endif()
 
-add_library(galera_smm_static
+add_library(galera_smm_static STATIC
   wsrep_provider.cpp
   )
 
@@ -71,8 +71,7 @@ target_compile_options(galera_smm_static
 
 target_link_libraries(galera_smm_static galera)
 
-add_library(galera_smm
-  MODULE
+add_library(galera_smm  MODULE
   wsrep_provider.cpp
   )
 
diff --git a/galerautils/src/CMakeLists.txt b/galerautils/src/CMakeLists.txt
index cbdb0ab2..0fd80119 100644
--- a/galerautils/src/CMakeLists.txt
+++ b/galerautils/src/CMakeLists.txt
@@ -2,6 +2,14 @@
 # Copyright (C) 2020 Codership Oy <i...@codership.com>
 #
 
+# Logging facility is extracted into separate library to break
+# circular dependency between crc32c HW and galerautils libraries.
+add_library(galerautils_log STATIC
+  gu_log.c)
+target_compile_options(galerautils_log
+  PRIVATE
+  -Wno-unused-parameter)
+
 #
 # Compile hardware optimized CRC32C code into separate library
 # to keep the optimized code isolated.
@@ -14,19 +22,20 @@ endif()
 
 if (GALERAUTILS_HW_CRC32C_SOURCES)
   set(GALERAUTILS_HW_CRC32C_LIB galerautils_hw_crc32c)
-  add_library(${GALERAUTILS_HW_CRC32C_LIB} ${GALERAUTILS_HW_CRC32C_SOURCES})
+  add_library(${GALERAUTILS_HW_CRC32C_LIB} STATIC
+    ${GALERAUTILS_HW_CRC32C_SOURCES})
   target_compile_options(${GALERAUTILS_HW_CRC32C_LIB}
     PRIVATE
     ${GALERA_CRC32C_COMPILER_FLAG})
+  target_link_libraries(${GALERAUTILS_HW_CRC32C_LIB} galerautils_log)
 endif()
 
-add_library(galerautils
+add_library(galerautils STATIC
   gu_abort.c
   gu_crc32c.c
   gu_dbug.c
   gu_fifo.c
   gu_lock_step.c
-  gu_log.c
   gu_mem.c
   gu_mmh3.c
   gu_spooky.c
@@ -53,10 +62,11 @@ target_compile_options(galerautils
   -Wno-unused-parameter)
 
 target_link_libraries(galerautils
+  galerautils_log
   ${GALERAUTILS_HW_CRC32C_LIB}
   ${GALERA_SYSTEM_LIBS})
 
-add_library(galerautilsxx
+add_library(galerautilsxx STATIC
   gu_vlq.cpp
   gu_datetime.cpp
   gu_gtid.cpp
diff --git a/gcache/src/CMakeLists.txt b/gcache/src/CMakeLists.txt
index 57a21b29..409ed3fe 100644
--- a/gcache/src/CMakeLists.txt
+++ b/gcache/src/CMakeLists.txt
@@ -6,7 +6,7 @@
 # GCache library
 #
 
-add_library(gcache
+add_library(gcache STATIC
   GCache_seqno.cpp
   gcache_params.cpp
   gcache_page.cpp
diff --git a/gcomm/src/CMakeLists.txt b/gcomm/src/CMakeLists.txt
index a7bb10c1..7f001586 100644
--- a/gcomm/src/CMakeLists.txt
+++ b/gcomm/src/CMakeLists.txt
@@ -2,7 +2,7 @@
 # Copyright (C) 2020 Codership Oy <i...@codership.com>
 #
 
-add_library(gcomm
+add_library(gcomm STATIC
   asio_protonet.cpp
   asio_tcp.cpp
   asio_udp.cpp
diff --git a/gcs/src/CMakeLists.txt b/gcs/src/CMakeLists.txt
index b81d7c82..bd14cb39 100644
--- a/gcs/src/CMakeLists.txt
+++ b/gcs/src/CMakeLists.txt
@@ -28,7 +28,7 @@ set(GCS_SOURCES
 # Gcs library.
 #
 
-add_library(gcs ${GCS_SOURCES})
+add_library(gcs STATIC ${GCS_SOURCES})
 
 target_compile_definitions(gcs
   PRIVATE
@@ -54,7 +54,7 @@ target_link_libraries(gcs gcomm gcache)
 # Gcs library for Garb daemon.
 #
 
-add_library(gcs4garb ${GCS_SOURCES})
+add_library(gcs4garb STATIC ${GCS_SOURCES})
 
 target_compile_definitions(gcs4garb
   PRIVATE

++++++ fix-cmake-install.patch ++++++
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3e65edbc..53e68817 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -12,6 +12,7 @@ include(CheckIncludeFile)
 include(CheckIncludeFileCXX)
 include(CheckCXXCompilerFlag)
 include(CheckLibraryExists)
+include(GNUInstallDirs)
 
 include_directories(
   ${CMAKE_SOURCE_DIR}
@@ -42,6 +43,9 @@ option(GALERA_GCS_SM_DEBUG
 option(GALERA_GU_DEBUG_MUTEX "Enable mutex debug instrumentation" OFF)
 option(GALERA_GU_DBUG_ON "Enable sync point macros (ON for Debug builds)" OFF)
 
+option(GALERA_SYSTEMD_UNITDIR "The directory where the systemd units will be 
installed"
+       ${CMAKE_INSTALL_LIBDIR}/systemd/system)
+
 #
 # Set cmake policies before doing any checks.
 #
@@ -111,9 +115,9 @@ if (NOT ${CMAKE_SYSTEM_NAME} MATCHES ".*BSD")
     ${CMAKE_SOURCE_DIR}/AUTHORS
     ${CMAKE_SOURCE_DIR}/COPYING
     ${CMAKE_SOURCE_DIR}/README
-    DESTINATION doc)
+    DESTINATION ${CMAKE_INSTALL_DOCDIR})
   install(FILES ${CMAKE_SOURCE_DIR}/asio/LICENSE_1_0.txt
-    DESTINATION doc
+    DESTINATION ${CMAKE_INSTALL_DOCDIR}
     RENAME LICENSE.asio)
 endif()
 
diff --git a/galera/src/CMakeLists.txt b/galera/src/CMakeLists.txt
index cc7775d7..c3c573a0 100644
--- a/galera/src/CMakeLists.txt
+++ b/galera/src/CMakeLists.txt
@@ -112,7 +112,7 @@ endif()
 
 target_link_libraries(galera_smm galera ${GALERA_LINK_OPTIONS})
 
-install(TARGETS galera_smm DESTINATION lib)
+install(TARGETS galera_smm DESTINATION ${CMAKE_INSTALL_LIBDIR})
 
 # The following checks are guaranteed to work only
 # Linux platform, we skip them on others.
diff --git a/garb/CMakeLists.txt b/garb/CMakeLists.txt
index 156b984b..57cf1b2c 100644
--- a/garb/CMakeLists.txt
+++ b/garb/CMakeLists.txt
@@ -31,14 +31,18 @@ target_compile_options(garbd
 target_link_libraries(garbd gcs4garb gcomm gcache
   ${Boost_PROGRAM_OPTIONS_LIBRARIES})
 
-install(TARGETS garbd DESTINATION bin)
+install(TARGETS garbd DESTINATION ${CMAKE_INSTALL_BINDIR})
 if (NOT ${CMAKE_SYSTEM_NAME} MATCHES ".*BSD")
   install(FILES
     ${CMAKE_CURRENT_SOURCE_DIR}/files/garb.cnf
+    DESTINATION ${CMAKE_INSTALL_SYSCONFDIR})
+  install(FILES
     ${CMAKE_CURRENT_SOURCE_DIR}/files/garb.service
+    DESTINATION ${GALERA_SYSTEMD_UNITDIR})
+  install(FILES
     ${CMAKE_CURRENT_SOURCE_DIR}/files/garb-systemd
-    DESTINATION share)
+    DESTINATION ${CMAKE_INSTALL_LIBEXECDIR})
   install(FILES
     ${CMAKE_SOURCE_DIR}/man/garbd.8
-    DESTINATION man/man8)
+    DESTINATION ${CMAKE_INSTALL_MANDIR}/man8)
 endif()
diff --git a/garb/files/garb.service b/garb/files/garb.service
index 926cf578..b862654f 100644
--- a/garb/files/garb.service
+++ b/garb/files/garb.service
@@ -12,7 +12,7 @@ Alias=garbd.service
 [Service]
 User=garb
 Group=garb
-ExecStart=/usr/bin/garb-systemd start
+ExecStart=/usr/libexec/garb-systemd start
 
 # Use SIGINT because with the default SIGTERM
 # garbd fails to reliably transition to 'destroyed' state

Reply via email to