From 318752ff9717c412f1590b498a1fffe9e22954db Mon Sep 17 00:00:00 2001 From: jammyjellyfish Date: Thu, 20 Apr 2023 13:20:36 +0800 Subject: [PATCH] Fix clang build error --- galera.spec | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/galera.spec b/galera.spec index aa37da6..2f5902b 100644 --- a/galera.spec +++ b/galera.spec @@ -1,7 +1,7 @@ %global galeradoc %{buildroot}%{_docdir}/galera Name: galera Version: 26.4.8 -Release: 2 +Release: 3 Summary: Synchronous multi-master replication library License: GPLv2 URL: http://galeracluster.com/ @@ -33,6 +33,11 @@ sed -i '/^GALERA_VER/s/API + //' wsrep/tests/SConscript CPPFLAGS=`echo $CPPFLAGS| sed -e "s|-Wp,-D_GLIBCXX_ASSERTIONS||g" ` CFLAGS=`echo $CFLAGS| sed -e "s|-Wp,-D_GLIBCXX_ASSERTIONS||g" ` CXXFLAGS=`echo $CXXFLAGS| sed -e "s|-Wp,-D_GLIBCXX_ASSERTIONS||g" ` +%if "%toolchain" == "clang" + CPPFLAGS="$CPPFLAGS -Wno-error=unused-but-set-variable" + CFLAGS="$CFLAGS -Wno-error=unused-but-set-variable" +%endif + export CPPFLAGS CFLAGS CXXFLAGS scons-3 %{?_smp_mflags} strict_build_flags=0 @@ -69,6 +74,9 @@ install -D -m 755 libgalera_smm.so %{buildroot}%{_libdir}/galera/li %{_unitdir}/garbd.service %changelog +* Thu Apr 20 2023 jammyjellyfish - 26.4.8-3 +- Fix clang build error + * Thu Dec 22 2022 wanglin - 26.4.8-2 - Set strict_build_flags=0 and fix changelog date -- Gitee