Name: libarchive Version: 2.8.5 Release: 1 Summary: A library for handling streaming archive formats Group: System Environment/Libraries License: BSD URL: http://code.google.com/p/libarchive/ Source0: http://libarchive.googlecode.com/files/%{name}-%{version}.tar.gz Patch0: %{name}-%{version}-aix.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRequires: zlib-devel, bzip2, openssl >= 0.9.8 BuildRequires: xz-devel, libxml2-devel >= 2.6.32-2 Requires: zlib-devel, bzip2, openssl-devel >= 0.9.8 Requires: xz-libs, libxml2 >= 2.6.32-2 %description Libarchive is a programming library that can create and read several different streaming archive formats, including most popular tar variants, several cpio formats, and both BSD and GNU ar variants. It can also write shar archives and read ISO9660 CDROM images and ZIP archives. %package devel Summary: Development files for %{name} Group: Development/Libraries Requires: %{name} = %{version}-%{release} %description devel The %{name}-devel package contains libraries and header files for developing applications that use %{name}. %prep %setup -q %patch0 %build export CONFIG_SHELL=/usr/bin/ksh export CONFIG_ENV_ARGS=/usr/bin/ksh export CC="cc -qcpluscmt" # first build the 64-bit version export OBJECT_MODE=64 ./configure \ --prefix=%{_prefix} \ --mandir=%{_mandir} \ --enable-shared --disable-static \ --disable-bsdtar \ --disable-bsdcpio make %{?_smp_mflags} cp ./.libs/%{name}.so.2 . make distclean # now build the 32-bit version export OBJECT_MODE=32 ./configure \ --prefix=%{_prefix} \ --mandir=%{_mandir} \ --enable-shared --disable-static make %{?_smp_mflags} # add the 64-bit shared objects to the shared library containing already the # 32-bit shared object ar -X64 -q ./.libs/%{name}.a ./%{name}.so.2 %install [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} make DESTDIR=${RPM_BUILD_ROOT} install /usr/bin/strip ${RPM_BUILD_ROOT}%{_bindir}/* || : ( cd ${RPM_BUILD_ROOT} for dir in bin include lib do mkdir -p usr/${dir} cd usr/${dir} ln -sf ../..%{_prefix}/${dir}/* . cd - done ) %clean [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} %files %defattr(-,root,system,-) %doc COPYING README NEWS %{_bindir}/* %{_libdir}/*.a /usr/bin/* /usr/lib/*.a %files devel %defattr(-,root,system,-) %{_includedir}/* %{_libdir}/*.la %{_libdir}/pkgconfig/%{name}.pc %{_mandir}/man1/* %{_mandir}/man3/* %{_mandir}/man5/* /usr/include/* /usr/lib/*.la %changelog * Mon Nov 21 2011 Michael Perzl - 2.8.5-1 - updated to version 2.8.5 * Thu Oct 07 2010 Michael Perzl - 2.8.4-1 - updated to version 2.8.4 * Tue Mar 23 2010 Michael Perzl - 2.8.3-1 - updated to version 2.8.3, enabled build of bsdcpio and bsdtar * Fri Apr 24 2009 Michael Perzl - 2.7.0-1 - first version for AIX V5.1 and higher