%ifos aix6.1 || %ifos aix7.1 %global p7build 1 %else %global p7build 0 %endif Summary: The GNU data compression program Name: gzip Version: 1.10 %if %{p7build} Release: 1.p7 %else Release: 1 %endif # info pages are under GFDL license License: GPLv3+ and GFDL Group: Applications/File URL: http://www.gzip.org/ Source0: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.gz Source1: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.gz.sig Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root Requires: /sbin/install-info, info %if %{p7build} %ifos aix6.1 Requires: AIX-rpm >= 6.1.8.0 %endif %ifos aix7.1 Requires: AIX-rpm >= 7.1.3.0 %endif %endif %description The gzip package contains the popular GNU gzip data compression program. Gzipped files have a .gz extension. Gzip should be installed on your system, because it is a very commonly used data compression program. %prep %setup -q %build export CC="cc_r -qcpluscmt -D_LARGE_FILES -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE" export RM="/usr/bin/rm -f" ./configure \ --prefix=%{_prefix} \ --mandir=%{_mandir} \ --infodir=%{_infodir} \ --enable-largefile make %{?_smp_mflags} %install [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} make DESTDIR=${RPM_BUILD_ROOT} install /usr/bin/strip ${RPM_BUILD_ROOT}%{_bindir}/gzip || : # remove dependency on bash cd ${RPM_BUILD_ROOT}%{_bindir} filelist=`ls -1 | grep -v gzip` for i in `echo $filelist` ; do sed -e "s|/opt/freeware/bin/bash|/bin/sh|g" < ${RPM_BUILD_ROOT}%{_bindir}/$i > ${RPM_BUILD_ROOT}%{_bindir}/.$i rm -f ${RPM_BUILD_ROOT}%{_bindir}/$i mv ${RPM_BUILD_ROOT}%{_bindir}/.$i ${RPM_BUILD_ROOT}%{_bindir}/$i chmod 755 ${RPM_BUILD_ROOT}%{_bindir}/$i done gzip --best ${RPM_BUILD_ROOT}%{_infodir}/gzip.info* rm -f ${RPM_BUILD_ROOT}%{_infodir}/dir mkdir -p ${RPM_BUILD_ROOT}/usr/bin cd ${RPM_BUILD_ROOT}/usr/bin ln -s ../..%{_bindir}/* . rm -f uncompress zcat mkdir -p ${RPM_BUILD_ROOT}/usr/linux/bin cd ${RPM_BUILD_ROOT}/usr/linux/bin ln -s ../../..%{_bindir}/* . %post if [ -f %{_infodir}/gzip.info* ]; then /sbin/install-info %{_infodir}/gzip.info.gz %{_infodir}/dir || : fi %preun if [ $1 = 0 ]; then /sbin/install-info --delete %{_infodir}/gzip.info.gz %{_infodir}/dir || : fi %clean [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} %files %defattr(-,root,system) %doc NEWS README AUTHORS ChangeLog THANKS TODO %{_bindir}/* %{_mandir}/*/* %{_infodir}/gzip.info* /usr/bin/* /usr/linux/bin/* %changelog * Sun Dec 30 2018 Michael Perzl - 1.10-1 - updated to version 1.10 * Tue Jun 12 2018 Michael Perzl - 1.9-1 - updated to version 1.9 * Fri Apr 29 2016 Michael Perzl - 1.8-1 - updated to version 1.8 * Fri Apr 29 2016 Michael Perzl - 1.7-1 - updated to version 1.7 * Mon Apr 04 2016 Michael Perzl - 1.6-1 - updated to version 1.6 * Sun Jun 17 2012 Michael Perzl - 1.5-1 - updated to version 1.5 * Thu Apr 22 2010 Michael Perzl - 1.4-1 - updated to version 1.4 * Thu Mar 27 2008 Michael Perzl - 1.3.12-1 - first version for AIX V5.1 and higher