Summary: Archiver for .arj files Name: arj Version: 3.10.22 Release: 1 License: GPL+ Group: Applications/Archiving URL: http://arj.sourceforge.net/ Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz # unarj.* from Debian Source1: unarj.sh Source2: unarj.1 Patch0: http://ftp.debian.org/debian/pool/main/a/%{name}/%{name}_%{version}-6.diff.gz Patch1: %{name}-%{version}-missing-protos.patch Patch2: %{name}-%{version}-custom-printf.patch # Filed into upstream bugtracker as https://sourceforge.net/tracker/?func=detail&aid=2853421&group_id=49820&atid=457566 Patch3: %{name}-%{version}-quotes.patch Patch10: %{name}-%{version}-aix.patch BuildRequires: autoconf, patch, coreutils, make, sed BuildRequires: gcc >= 4.2.3-2 Provides: unarj = %{version}-%{release} Obsoletes: unarj < 3 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root %description This package is an open source version of the arj archiver. It has been created with the intent to preserve maximum compatibility and retain the feature set of original ARJ archiver as provided by ARJ Software, Inc. %prep %setup -q export PATH=/opt/freeware/bin:$PATH %patch0 -p1 %patch1 -p1 %patch2 -p1 %patch3 -p1 for i in debian/patches/00*.patch; do patch -p1 < $i done %patch10 cd gnu autoconf %build export PATH=/opt/freeware/bin:$PATH export CC="gcc -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES" export CFLAGS="-DSYSV -D_AIX -D_AIX32 -D_AIX41 -D_AIX43 -D_AIX51 -D_ALL_SOURCE -DFUNCPROTO=15 -O -I/opt/freeware/include" export LD=ld export LDFLAGS="-L/opt/freeware/lib -Wl,-blibpath:/opt/freeware/lib:/usr/lib:/lib -Wl,-bmaxdata:0x80000000" cd gnu ./configure \ --prefix=%{_prefix} \ --mandir=%{_mandir} cd .. gmake %{?_smp_mflags} %install [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} export PATH=/opt/freeware/bin:$PATH gmake DESTDIR=${RPM_BUILD_ROOT} install /usr/bin/strip ${RPM_BUILD_ROOT}%{_bindir}/* || : install -Dpm 644 resource/rearj.cfg.example $RPM_BUILD_ROOT%{_sysconfdir}/rearj.cfg install -pm 755 %{SOURCE1} ${RPM_BUILD_ROOT}%{_bindir}/unarj install -pm 644 %{SOURCE2} ${RPM_BUILD_ROOT}%{_mandir}/man1/unarj.1 # remove the register remainders of arj's sharewares time rm -f ${RPM_BUILD_ROOT}%{_bindir}/arj-register rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/arj-register.1* cd ${RPM_BUILD_ROOT} mkdir -p usr/bin cd usr/bin ln -sf ../..%{_bindir}/* . %clean [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} %files %defattr(-,root,system) %doc ChangeLog* doc/COPYING doc/rev_hist.txt %config(noreplace) %{_sysconfdir}/rearj.cfg %{_bindir}/*%{name}* %{_libdir}/%{name} %{_mandir}/man1/*%{name}*.1 /usr/bin/*%{name}* %changelog * Mon Jan 10 2011 Michael Perzl - 3.10.22-1 - first version for AIX V5.1 and higher