From f7574462bab277ead7faa6b51f18df1f78c5a9d303fe14bd8a56a87a392415fd Mon Sep 17 00:00:00 2001 From: Lidong Zhong Date: Fri, 21 Nov 2014 02:58:32 +0000 Subject: [PATCH 1/2] Accepting request 261986 from home:Ledest:bashisms fix bashisms in mem_leak_test.sh script and preun script OBS-URL: https://build.opensuse.org/request/show/261986 OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/corosync?expand=0&rev=59 --- corosync-2.3.4-fix-bashisms.patch | 34 +++++++++++++++++++++++++++++++ corosync.changes | 12 +++++++++++ corosync.spec | 4 +++- 3 files changed, 49 insertions(+), 1 deletion(-) create mode 100644 corosync-2.3.4-fix-bashisms.patch diff --git a/corosync-2.3.4-fix-bashisms.patch b/corosync-2.3.4-fix-bashisms.patch new file mode 100644 index 0000000..b9e5268 --- /dev/null +++ b/corosync-2.3.4-fix-bashisms.patch @@ -0,0 +1,34 @@ +diff -Ndur corosync-2.3.4/cts/agents/mem_leak_test.sh corosync-2.3.4-fix-bashisms/cts/agents/mem_leak_test.sh +--- corosync-2.3.4/cts/agents/mem_leak_test.sh 2014-08-12 10:27:36.000000000 +0300 ++++ corosync-2.3.4-fix-bashisms/cts/agents/mem_leak_test.sh 2014-11-17 05:57:38.986640342 +0200 +@@ -41,14 +41,14 @@ + find $f | sed "s|\.|_|g" | sed "s|/|.|g" | while read l + do + echo $l.count u64 $COUNT >> $temp_file +- let COUNT="$COUNT+1" ++ COUNT=$((COUNT + 1)) + done + + corosync-cmapctl -p $temp_file + corosync-cmapctl -D usr + done + AFTER=$(get_mem $TYPE) +- let DIFF="$AFTER - $BEFORE" ++ DIFF=$((AFTER - BEFORE)) + rm -f $temp_file + #echo $f diff $TYPE $DIFF + echo $DIFF +@@ -76,11 +76,11 @@ + find /usr/bin | sed "s|\.|_|g" | sed "s|/|.|g" | while read l + do + corosync-cmapctl -s $l u32 $COUNT +- let COUNT="$COUNT+1" ++ COUNT=$((COUNT + 1)) + done + corosync-cmapctl -D usr + AFTER=$(get_mem $TYPE) +- let DIFF="$AFTER - $BEFORE" ++ DIFF=$((AFTER - BEFORE)) + echo $DIFF + + exit 0 diff --git a/corosync.changes b/corosync.changes index e9ee5a2..7be37d4 100644 --- a/corosync.changes +++ b/corosync.changes @@ -1,3 +1,15 @@ +------------------------------------------------------------------- +Mon Nov 17 04:01:00 UTC 2014 - Led + +- fix bashisms in mem_leak_test.sh script +- add patches: + * corosync-2.3.4-fix-bashisms.patch + +------------------------------------------------------------------- +Mon Nov 17 04:00:00 UTC 2014 - Led + +- fix bashism in preun script + ------------------------------------------------------------------- Mon Sep 1 08:01:50 UTC 2014 - xli@suse.com diff --git a/corosync.spec b/corosync.spec index c114f7b..64c892a 100644 --- a/corosync.spec +++ b/corosync.spec @@ -52,6 +52,7 @@ Source2: baselibs.conf Patch1: corosync-init-lockfile-path-error.patch Patch2: bnc#872651-stop-cluster.patch Patch3: bnc#882449-corosync-conf-example.patch +Patch4: corosync-2.3.4-fix-bashisms.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build # openais is indeed gone and should be uninstalled. Yes, we do not # provide openais on purpose, the package has been deleted. @@ -99,6 +100,7 @@ Requires: libxslt %patch1 -p1 %patch2 -p1 %patch3 -p1 +%patch4 -p1 %build #%if 0%{?buildtrunk} == 1 @@ -199,7 +201,7 @@ fi %service_del_preun corosync.service corosync-notifyd.service %else if [ $1 -eq 0 ]; then - /sbin/service corosync stop &>/dev/null || : + /sbin/service corosync stop >/dev/null 2>&1 ||: /sbin/chkconfig --del corosync || : fi %endif From 4cc777104238c1091b44c788ae30dd459d87a52795df4b35a8d3cf80aab41b45 Mon Sep 17 00:00:00 2001 From: Lidong Zhong Date: Fri, 21 Nov 2014 02:59:30 +0000 Subject: [PATCH 2/2] Accepting request 262383 from home:dimstar:branches:network:ha-clustering:Factory - Replace systemd BuildRequires with pkgconfig(systemd): we do not require the full installation / dep chain of systemd. OBS-URL: https://build.opensuse.org/request/show/262383 OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/corosync?expand=0&rev=60 --- corosync.changes | 6 ++++++ corosync.spec | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/corosync.changes b/corosync.changes index 7be37d4..23cb64c 100644 --- a/corosync.changes +++ b/corosync.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Nov 19 22:24:13 UTC 2014 - dimstar@opensuse.org + +- Replace systemd BuildRequires with pkgconfig(systemd): we do not + require the full installation / dep chain of systemd. + ------------------------------------------------------------------- Mon Nov 17 04:01:00 UTC 2014 - Led diff --git a/corosync.spec b/corosync.spec index 64c892a..671d170 100644 --- a/corosync.spec +++ b/corosync.spec @@ -86,7 +86,7 @@ BuildRequires: net-snmp-devel BuildRequires: dbus-1-devel %endif %if %{with_systemd} -BuildRequires: systemd +BuildRequires: pkgconfig(systemd) Requires(post): systemd Requires(preun): systemd Requires(postun): systemd