From 3379b020ffb1915cc8f52e8013cfdc98acb8b9b849c64689d115bfb2c3398058 Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Wed, 5 Nov 2014 16:27:23 +0000 Subject: [PATCH] Accepting request 259536 from home:Ledest:misc fix bashisms in bzgrep and bznew scripts (2nd attempt) OBS-URL: https://build.opensuse.org/request/show/259536 OBS-URL: https://build.opensuse.org/package/show/Archiving/bzip2?expand=0&rev=44 --- bzip2-1.0.6-fix-bashisms.patch | 14 ++++++++++++++ bzip2.changes | 7 +++++++ bzip2.spec | 2 ++ bznew.gz | 4 ++-- 4 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 bzip2-1.0.6-fix-bashisms.patch diff --git a/bzip2-1.0.6-fix-bashisms.patch b/bzip2-1.0.6-fix-bashisms.patch new file mode 100644 index 0000000..afcad97 --- /dev/null +++ b/bzip2-1.0.6-fix-bashisms.patch @@ -0,0 +1,14 @@ +diff -Ndurp bzip2-1.0.6/bzgrep bzip2-1.0.6-fix-bashisms/bzgrep +--- bzip2-1.0.6/bzgrep 2007-01-03 04:00:55.000000000 +0200 ++++ bzip2-1.0.6-fix-bashisms/bzgrep 2014-10-19 02:07:30.036033876 +0300 +@@ -63,9 +63,7 @@ for i do + bzip2 -cdfq "$i" | $grep $opt "$pat" + r=$? + else +- j=${i//\\/\\\\} +- j=${j//|/\\|} +- j=${j//&/\\&} ++ j=$(echo "$i" | sed 's/\\/&&/g;s/|/\\&/g;s/&/\\&/g') + j=`printf "%s" "$j" | tr '\n' ' '` + bzip2 -cdfq "$i" | $grep $opt "$pat" | sed "s|^|${j}:|" + r=$? diff --git a/bzip2.changes b/bzip2.changes index 09ca464..b959ac4 100644 --- a/bzip2.changes +++ b/bzip2.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Mon Nov 03 16:19:00 UTC 2014 - Led + +- fix basisms in bzgrep and bznew +- add patches: + * bzip2-1.0.6-fix-bashisms.patch + ------------------------------------------------------------------- Tue Sep 2 15:16:50 UTC 2014 - vcizek@suse.com diff --git a/bzip2.spec b/bzip2.spec index ab0bc31..274c23e 100644 --- a/bzip2.spec +++ b/bzip2.spec @@ -30,6 +30,7 @@ Source3: baselibs.conf Source100: bzip2-rpmlintrc # PATCH-FEATURE-OPENSUSE bzip2-1.0.6-autoconfiscated.patch sbrabec@suse.cz -- Convert to a standard autoconf based package. Patch: http://ftp.suse.com/pub/people/sbrabec/bzip2/for_downstream/bzip2-1.0.6-autoconfiscated.patch +Patch1: bzip2-1.0.6-fix-bashisms.patch Patch3: bzip2-faster.patch Patch5: bzip2-unsafe_strcpy.patch Patch6: bzip2-point-to-doc-pkg.patch @@ -79,6 +80,7 @@ The bzip2 runtime library development files. %prep %setup -q %patch +%patch1 -p1 %patch3 %patch5 %patch6 -p1 diff --git a/bznew.gz b/bznew.gz index 3100056..f13bf7f 100644 --- a/bznew.gz +++ b/bznew.gz @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d7e68e6d1c5a8d7aeb200c81cb5dbe7bf5eafa86d219e99a6da8ce724bff7d5 -size 1866 +oid sha256:b90b39c36f17bfabf06b03882e7330b79d11faa527af0eccf2810cc98023b304 +size 1864