unzip/unzip.spec

119 lines
3.7 KiB
RPMSpec

%define src_ver %(echo %version | tr -d .)
Name: unzip
Version: 6.0
Release: 4mamba
Summary: A file compression and packaging utility compatible with PKZIP
Group: Applications/Archiving
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: http://infozip.sourceforge.net/
Source: https://downloads.sourceforge.net/infozip/unzip%{src_ver}.tar.gz
Patch0: %{name}-5.51-rpmoptflags.patch
Patch1: %{name}-5.51-link-segv.patch
Patch2: %{name}-5.52-can-2005-2475.patch
Patch3: %{name}-5.52-CVE-2005-4667.patch
Patch4: %{name}-6.0-iconv.patch
Patch5: unzip-6.0-overflow-fsize.patch
Patch6: unzip-6.0-cve20149636.patch
Patch7: unzip-6.0-test_compr_eb.patch
Patch8: unzip-6.0-getZip64Data.patch
Patch9: unzip-6.0-crc32.patch
Patch10: unzip-6.0-empty-input.patch
Patch11: unzip-6.0-csiz-underflow.patch
Patch12: unzip-6.0-nextbyte-overflow.patch
License: BSD
## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel
BuildRequires: libbzip2-devel
## AUTOBUILDREQ-END
BuildRoot: %{_tmppath}/%{name}-%{version}-root
%description
The zip program is a compression and file packaging utility.
Zip is analogous to a combination of the UNIX tar and compress commands and is compatible with PKZIP (a compression and file packaging utility for MS-DOS systems).
Install the zip package if you need to compress files using the zip program.
%debug_package
%prep
%setup -q -n unzip%{src_ver}
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p0
%patch9 -p1
%patch10 -p1
%patch11 -p1
%patch12 -p1
ln -sf unix/Makefile Makefile
#sed -i "s|CC=gcc |CC=%{_host}-gcc |" Makefile
#sed -i "s|LD=gcc |LD=%{_host}-gcc |" Makefile
#sed -i "s|AS=gcc |AS=%{_host}-gcc |" Makefile
%build
# DEFINES, make, and install args from Debian
DEFINES='-DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT \
-DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD \
-DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DNOMEMCPY -DNO_WORKING_ISPRINT'
%make -f unix/Makefile prefix=/usr \
D_USE_BZ2=-DUSE_BZIP2 L_BZ2=-lbz2 \
LF2="" CF="%{optflags} -I. $DEFINES" \
unzips
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%makeoldinstall \
MANDIR=%{buildroot}%{_mandir}/man1
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%files
%defattr(-,root,root)
%{_bindir}/*
%{_mandir}/man1/*
%doc README BUGS LICENSE
%changelog
* Fri May 14 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 6.0-4mamba
- also fix and apply test_compr_eb patch
* Wed May 12 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 6.0-3mamba
- applied patches from Arch Linux
* Wed Nov 25 2020 Silvan Calarco <silvan.calarco@mambasoft.it> 6.0-2mamba
- rebuilt with debug package
* Wed Apr 27 2011 Silvan Calarco <silvan.calarco@mambasoft.it> 6.0-1mamba
- update to 6.0
* Tue Mar 11 2008 Silvan Calarco <silvan.calarco@mambasoft.it> 5.52-5mamba
- specfile updated
* Fri Mar 03 2006 Davide Madrisan <davide.madrisan@qilinux.it> 5.52-4qilnx
- security update for CVE-2005-4667
* Wed Oct 05 2005 Stefano Cotta Ramusino <stefano.cotta@qilinux.it> 5.52-3qilnx
- spec file fixed and updated
* Mon Oct 03 2005 Davide Madrisan <davide.madrisan@qilinux.it> 5.52-2qilnx
- security fix QSA-2005-112 (CAN-2005-2475)
* Wed Aug 03 2005 Davide Madrisan <davide.madrisan@qilinux.it> 5.52-1qilnx
- update to version 5.52 by autospec
* Mon Apr 18 2005 Davide Madrisan <davide.madrisan@qilinux.it> 5.51-1qilnx
- update to version 5.51 by autospec
- fixed manpages path
- fix several problem with unpacking zipfiles containing symlinks
* Mon Jul 14 2003 Silvan Calarco <silvan.calarco@qinet.it> 5.50-1qilnx
- creation of unzip package