From 677c28a9bfc52e22bba3fed95c1cb6985503095c Mon Sep 17 00:00:00 2001 From: laokz Date: Wed, 20 Sep 2023 20:35:53 +0800 Subject: [PATCH] make with_mem_leak_test option following %{valgrind_arches} (cherry picked from commit 95a20ed610c4e8739c7be0326a8ab0cbbdec4dcb) --- libstoragemgmt.spec | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/libstoragemgmt.spec b/libstoragemgmt.spec index bdab2d6..ee380b4 100644 --- a/libstoragemgmt.spec +++ b/libstoragemgmt.spec @@ -2,7 +2,7 @@ %define with_python2 0 Name: libstoragemgmt Version: 1.9.6 -Release: 1 +Release: 2 Summary: Storage array management library License: LGPLv2+ URL: https://github.com/libstorage/libstoragemgmt @@ -10,7 +10,10 @@ Source0: https://github.com/libstorage/libstoragemgmt/releases/download/%{versio BuildRequires: gcc gcc-c++ autoconf automake libtool libxml2-devel check-devel perl-interpreter BuildRequires: glib2-devel systemd bash-completion libconfig-devel systemd-devel -BuildRequires: procps sqlite-devel python3-six python3-devel systemd systemd-devel chrpath valgrind +BuildRequires: procps sqlite-devel python3-six python3-devel systemd systemd-devel chrpath +%ifarch %{valgrind_arches} +BuildRequires: valgrind +%endif %{?systemd_requires} %if 0%{?with_python2} @@ -152,7 +155,12 @@ rm -fr %{py2_build_dir} cp -a . %{py2_build_dir} %endif -%configure --with-python3 +%ifarch %{valgrind_arches} +WITHOUT_VALGRIND= +%else +WITHOUT_VALGRIND=--without-mem-leak-test +%endif +%configure --with-python3 $WITHOUT_VALGRIND %make_build %if 0%{?with_python2} @@ -395,6 +403,9 @@ fi %{_mandir}/man*/* %changelog +* Wed Sep 20 2023 laokz - 1.9.6-2 +- make with_mem_leak_test option following %{valgrind_arches} + * Tue Feb 7 2023 xu_ping - 1.9.6-1 - Upgrade 1.9.6 -- Gitee