From 18e495c8bbb9582329b3097401b11991839dd68b Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Apr 10 2018 05:50:42 +0000 Subject: import unzip-6.0-19.el7 --- diff --git a/SOURCES/unzip-6.0-configure.patch b/SOURCES/unzip-6.0-configure.patch new file mode 100644 index 0000000..9eead42 --- /dev/null +++ b/SOURCES/unzip-6.0-configure.patch @@ -0,0 +1,12 @@ +diff -up unzip60/unix/configure.nostrip unzip60/unix/configure +--- unzip60/unix/configure.nostrip 2009-11-30 10:18:09.000000000 +0100 ++++ unzip60/unix/configure 2009-11-30 10:21:08.354264213 +0100 +@@ -17,7 +17,7 @@ CFLAGSR=${CFLAGS} + IZ_BZIP2=${3} + CFLAGS="${CFLAGS} -I. -DUNIX" + LFLAGS1="" +-LFLAGS2="-s" ++LFLAGS2="${LFLAGS2}" + LN="ln -s" + + CFLAGS_OPT='' diff --git a/SOURCES/unzip-6.0-nostrip.patch b/SOURCES/unzip-6.0-nostrip.patch deleted file mode 100644 index 71c263f..0000000 --- a/SOURCES/unzip-6.0-nostrip.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up unzip60/unix/configure.nostrip unzip60/unix/configure ---- unzip60/unix/configure.nostrip 2009-11-30 10:18:09.000000000 +0100 -+++ unzip60/unix/configure 2009-11-30 10:21:08.354264213 +0100 -@@ -17,7 +17,7 @@ CFLAGSR=${CFLAGS} - IZ_BZIP2=${3} - CFLAGS="${CFLAGS} -I. -DUNIX" - LFLAGS1="" --LFLAGS2="-s" -+LFLAGS2="" - LN="ln -s" - - CFLAGS_OPT='' diff --git a/SPECS/unzip.spec b/SPECS/unzip.spec index 8ef5aa1..1bbb9a0 100644 --- a/SPECS/unzip.spec +++ b/SPECS/unzip.spec @@ -1,7 +1,7 @@ Summary: A utility for unpacking zip files Name: unzip Version: 6.0 -Release: 16%{?dist} +Release: 19%{?dist} License: BSD Group: Applications/Archiving Source: http://downloads.sourceforge.net/infozip/unzip60.tar.gz @@ -16,7 +16,7 @@ Patch3: unzip-6.0-close.patch Patch4: unzip-6.0-attribs-overflow.patch # Not sent to upstream, as it's Fedora/RHEL specific. # Modify the configure script not to request the strip of binaries. -Patch5: unzip-6.0-nostrip.patch +Patch5: unzip-6.0-configure.patch Patch6: unzip-6.0-manpage-fix.patch # Update match.c with recmatch() from zip 3.0's util.c # This also resolves the license issue in that old function. @@ -35,6 +35,7 @@ Patch15: unzip-6.0-alt-iconv-utf8.patch Patch16: unzip-6.0-alt-iconv-utf8-print.patch Patch17: unzip-6.0-symlink.patch + #Patch14: unzip-6.0-alt-iconv-utf8.patch #Patch15: unzip-6.0-symlink.patch #Patch16: unzip-6.0-format-secure.patch @@ -75,8 +76,15 @@ a zip archive. %patch16 -p1 -b .utf-print %patch17 -p1 -b .symlink + # Settings for EL <= 7 +%if 0%{?rhel} && 0%{?rhel} <= 7 +%{!?__global_ldflags: %global __global_ldflags -Wl,-z,relro} +%endif + + + %build -make -f unix/Makefile CF_NOOPT="-I. -DUNIX $RPM_OPT_FLAGS" generic_gcc %{?_smp_mflags} +make -f unix/Makefile CF_NOOPT="-I. -DUNIX $RPM_OPT_FLAGS -DNOMEMCPY -DNO_LCHMOD" LFLAGS2="%{?__global_ldflags}" generic_gcc %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT @@ -89,6 +97,21 @@ make -f unix/Makefile prefix=$RPM_BUILD_ROOT%{_prefix} MANDIR=$RPM_BUILD_ROOT/%{ %{_mandir}/*/* %changelog +* Tue Jan 09 2018 Jakub Martisko - 6.0-19 +- rename patch unzip-6.0-nostrip.patch to unzip-6.0-configure.patch +- make linking flags configurable from the specc file +- set linking flags to use relro hardening + Related: #1531116 + +* Tue Jan 09 2018 Jakub Martisko - 6.0-18 +- Add -DNOLCHMOD build option, since lchmod is not availabel on Linux + Anyway + Related: #1531116 + +* Thu Jan 04 2018 Jakub Martisko - 6.0-17 +- Fix error with wrong CRC checks by adding -DNOMEMCPY flag + Resolves: #1525636 + * Wed Nov 25 2015 Petr Stodulka - 6.0-16 - Added patch for build option "-Werror=format-security" - Added support of non-unicode non-latin charset