From d420de1b87a13bdf0f75a1c30c658a25977bd4de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucio=20Andr=C3=A9s=20Illanes=20Albornoz?= Date: Sun, 13 Oct 2019 16:16:48 +0000 Subject: vars/build.vars:bzip2: updated to v1.0.8 (via Redfoxmoon.) patches/bzip2/CVE-2016-3189.patch: removes obsolete patch (via Redfoxmoon.) patches/bzip2/bzip2-1.0.4-POSIX-shell.patch: removes obsolete patch (via Redfoxmoon.) patches/bzip2/bzip2-1.0.4-makefile-CFLAGS.patch: via Redfoxmoon. patches/bzip2/bzip2-1.0.4-man-links.patch: updated (via Redfoxmoon.) patches/bzip2/bzip2-1.0.6-saneso.patch: removes obsolete patch (via Redfoxmoon.) patches/bzip2/saneso.patch: via Redfoxmoon. --- patches/bzip2/CVE-2016-3189.patch | 12 ------------ patches/bzip2/bzip2-1.0.4-POSIX-shell.patch | 21 --------------------- patches/bzip2/bzip2-1.0.4-makefile-CFLAGS.patch | 25 +++++++++++++++++++++++++ patches/bzip2/bzip2-1.0.4-man-links.patch | 6 +++--- patches/bzip2/bzip2-1.0.6-saneso.patch | 13 ------------- patches/bzip2/saneso.patch | 23 +++++++++++++++++++++++ vars/build.vars | 8 ++++---- 7 files changed, 55 insertions(+), 53 deletions(-) delete mode 100644 patches/bzip2/CVE-2016-3189.patch delete mode 100644 patches/bzip2/bzip2-1.0.4-POSIX-shell.patch create mode 100644 patches/bzip2/bzip2-1.0.4-makefile-CFLAGS.patch delete mode 100644 patches/bzip2/bzip2-1.0.6-saneso.patch create mode 100644 patches/bzip2/saneso.patch diff --git a/patches/bzip2/CVE-2016-3189.patch b/patches/bzip2/CVE-2016-3189.patch deleted file mode 100644 index 6622670c..00000000 --- a/patches/bzip2/CVE-2016-3189.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/bzip2recover.c b/bzip2recover.c -index f9de049..d159c92 100644 ---- a/bzip2recover.c -+++ b/bzip2recover.c -@@ -457,6 +457,7 @@ Int32 main ( Int32 argc, Char** argv ) - bsPutUChar ( bsWr, 0x50 ); bsPutUChar ( bsWr, 0x90 ); - bsPutUInt32 ( bsWr, blockCRC ); - bsClose ( bsWr ); -+ outFile = NULL; - } - if (wrBlock >= rbCtr) break; - wrBlock++; diff --git a/patches/bzip2/bzip2-1.0.4-POSIX-shell.patch b/patches/bzip2/bzip2-1.0.4-POSIX-shell.patch deleted file mode 100644 index a5916eaf..00000000 --- a/patches/bzip2/bzip2-1.0.4-POSIX-shell.patch +++ /dev/null @@ -1,21 +0,0 @@ -bzgrep uses !/bin/sh but then uses the bashism ${var//} so replace those -with calls to sed so POSIX shells work - -http://bugs.gentoo.org/193365 - ---- ./bzgrep -+++ ./bzgrep -@@ -63,10 +63,9 @@ - bzip2 -cdfq "$i" | $grep $opt "$pat" - r=$? - else -- j=${i//\\/\\\\} -- j=${j//|/\\|} -- j=${j//&/\\&} -- j=`printf "%s" "$j" | tr '\n' ' '` -+ # the backslashes here are doubled up as we have to escape each one for the -+ # shell and then escape each one for the sed expression -+ j=`printf "%s" "${i}" | sed -e 's:\\\\:\\\\\\\\:g' -e 's:[|]:\\\\|:g' -e 's:[&]:\\\\&:g' | tr '\n' ' '` - bzip2 -cdfq "$i" | $grep $opt "$pat" | sed "s|^|${j}:|" - r=$? - fi diff --git a/patches/bzip2/bzip2-1.0.4-makefile-CFLAGS.patch b/patches/bzip2/bzip2-1.0.4-makefile-CFLAGS.patch new file mode 100644 index 00000000..cf146188 --- /dev/null +++ b/patches/bzip2/bzip2-1.0.4-makefile-CFLAGS.patch @@ -0,0 +1,25 @@ +--- ./Makefile ++++ ./Makefile +@@ -18,10 +18,9 @@ + CC=gcc + AR=ar + RANLIB=ranlib +-LDFLAGS= + + BIGFILES=-D_FILE_OFFSET_BITS=64 +-CFLAGS=-Wall -Winline -O2 -g $(BIGFILES) ++CFLAGS+=-Wall -Winline $(BIGFILES) $(CPPFLAGS) + + # Where you want it installed when you do 'make install' + PREFIX=/usr/local +--- ./Makefile-libbz2_so ++++ ./Makefile-libbz2_so +@@ -24,7 +24,7 @@ + SHELL=/bin/sh + CC=gcc + BIGFILES=-D_FILE_OFFSET_BITS=64 +-CFLAGS=-fpic -fPIC -Wall -Winline -O2 -g $(BIGFILES) ++CFLAGS+=-fpic -fPIC -Wall -Winline $(BIGFILES) $(CPPFLAGS) + + OBJS= blocksort.o \ + huffman.o \ diff --git a/patches/bzip2/bzip2-1.0.4-man-links.patch b/patches/bzip2/bzip2-1.0.4-man-links.patch index db3978b5..2427d6a7 100644 --- a/patches/bzip2/bzip2-1.0.4-man-links.patch +++ b/patches/bzip2/bzip2-1.0.4-man-links.patch @@ -5,8 +5,8 @@ http://bugs.gentoo.org/172986 @@ -85,4 +85,7 @@ cp -f bzip2.1 $(PREFIX)/share/man/man1 chmod a+r $(PREFIX)/share/man/man1/bzip2.1 -+ ln -fs bzip2.1 $(PREFIX)/share/man/man1/bunzip2.1 -+ ln -fs bzip2.1 $(PREFIX)/share/man/man1/bzcat.1 -+ ln -fs bzip2.1 $(PREFIX)/share/man/man1/bzip2recover.1 ++ ln -s bzip2.1 $(PREFIX)/share/man/man1/bunzip2.1 ++ ln -s bzip2.1 $(PREFIX)/share/man/man1/bzcat.1 ++ ln -s bzip2.1 $(PREFIX)/share/man/man1/bzip2recover.1 cp -f bzlib.h $(PREFIX)/include chmod a+r $(PREFIX)/include/bzlib.h diff --git a/patches/bzip2/bzip2-1.0.6-saneso.patch b/patches/bzip2/bzip2-1.0.6-saneso.patch deleted file mode 100644 index 1968a63b..00000000 --- a/patches/bzip2/bzip2-1.0.6-saneso.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- ./Makefile-libbz2_so -+++ ./Makefile-libbz2_so -@@ -35,8 +35,8 @@ - bzlib.o - - all: $(OBJS) -- $(CC) -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.6 $(OBJS) -- $(CC) $(CFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.6 -+ $(CC) $(LDFLAGS) -shared -Wl,-soname -Wl,libbz2.so.1 -o libbz2.so.1.0.6 $(OBJS) -+ $(CC) $(LDFLAGS) $(CFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.6 - rm -f libbz2.so.1.0 - ln -s libbz2.so.1.0.6 libbz2.so.1.0 - diff --git a/patches/bzip2/saneso.patch b/patches/bzip2/saneso.patch new file mode 100644 index 00000000..529a0c20 --- /dev/null +++ b/patches/bzip2/saneso.patch @@ -0,0 +1,23 @@ +diff --git a/Makefile-libbz2_so b/Makefile-libbz2_so +index fb0f230..2c95a3a 100644 +--- a/Makefile-libbz2_so ++++ b/Makefile-libbz2_so +@@ -35,13 +35,13 @@ OBJS= blocksort.o \ + bzlib.o + + all: $(OBJS) +- $(CC) -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.8 $(OBJS) ++ $(CC) -shared -Wl,-soname -Wl,libbz2.so.1 -o libbz2.so.1.0.8 $(OBJS) + $(CC) $(CFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.8 +- rm -f libbz2.so.1.0 +- ln -s libbz2.so.1.0.8 libbz2.so.1.0 ++ rm -f libbz2.so.1 ++ ln -s libbz2.so.1.0.8 libbz2.so.1 + + clean: +- rm -f $(OBJS) bzip2.o libbz2.so.1.0.8 libbz2.so.1.0 bzip2-shared ++ rm -f $(OBJS) bzip2.o libbz2.so.1.0.8 libbz2.so.1 bzip2-shared + + blocksort.o: blocksort.c + $(CC) $(CFLAGS) -c blocksort.c + diff --git a/vars/build.vars b/vars/build.vars index 307c9f11..8ebdaced 100644 --- a/vars/build.vars +++ b/vars/build.vars @@ -739,12 +739,12 @@ NATIVE_PACKAGES_DEPS_PYTHON="${PREFIX}/bin/python2"; : ${PKG_APR_UTIL_CONFIGURE_ARGS_EXTRA:="--with-apr=${BUILD_WORKDIR}/apr-native-${DEFAULT_TARGET}/obj"}; : ${PKG_APR_UTIL_DEPS_PARENT:=apr}; : ${PKG_APR_UTIL_INSTALL_FILES:=bin/apu-1-config=${PREFIX}/bin/${DEFAULT_TARGET}-apu-1-config}; -: ${PKG_BZIP2_SHA256SUM:=d70a9ccd8bdf47e302d96c69fecd54925f45d9c7b966bb4ef5f56b770960afa7}; -: ${PKG_BZIP2_VERSION:=1.0.6}; -: ${PKG_BZIP2_URL:=https://fossies.org/linux/misc/bzip2-${PKG_BZIP2_VERSION}.tar.bz2}; +: ${PKG_BZIP2_SHA256SUM:=ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269}; +: ${PKG_BZIP2_VERSION:=1.0.8}; +: ${PKG_BZIP2_URL:=https://sourceware.org/pub/bzip2/bzip2-${PKG_BZIP2_VERSION}.tar.gz}; : ${PKG_BZIP2_CFLAGS_BUILD_EXTRA:=${LIB_PACKAGES_CFLAGS_CONFIGURE}}; : ${PKG_BZIP2_IN_TREE:=1}; -: ${PKG_BZIP2_INSTALL_FILES:="@bzdiff=bin/bzcmp @bzgrep=bin/bzegrep @bzgrep=bin/bzfgrep @bzmore=bin/bzless ../bzip2-${PKG_BZIP2_VERSION}/libbz2.so.1.0=lib/ ../bzip2-${PKG_BZIP2_VERSION}/libbz2.so.1.0.6=lib/"}; +: ${PKG_BZIP2_INSTALL_FILES:="@bzdiff=bin/bzcmp @bzgrep=bin/bzegrep @bzgrep=bin/bzfgrep @bzmore=bin/bzless ../bzip2-${PKG_BZIP2_VERSION}/libbz2.so.1=lib/ ../bzip2-${PKG_BZIP2_VERSION}/libbz2.so.1.0.8=lib/"}; : ${PKG_BZIP2_MAKEFLAGS_BUILD_EXTRA:=-f Makefile-libbz2_so}; : ${PKG_BZIP2_MAKE_INSTALL_VNAME:=PREFIX}; : ${PKG_LIBDMTX_SHA256SUM:=686bcfb44e50b96345aa53f41e285f2118a2cf87a333b69b74165a2e7ddca492}; -- cgit v1.2.3