Blame SPECS/libarchive.spec

9ec497
Name:           libarchive
9ec497
Version:        3.1.2
9ec497
Release:        5%{?dist}
9ec497
Summary:        A library for handling streaming archive formats
9ec497
9ec497
Group:          System Environment/Libraries
9ec497
License:        BSD
9ec497
URL:            http://www.libarchive.org/
9ec497
Source0:        http://www.libarchive.org/downloads/%{name}-%{version}.tar.gz
9ec497
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
9ec497
9ec497
9ec497
BuildRequires: bison
9ec497
BuildRequires: sharutils
9ec497
BuildRequires: zlib-devel
9ec497
BuildRequires: bzip2-devel
9ec497
BuildRequires: xz-devel
9ec497
BuildRequires: lzo-devel
9ec497
BuildRequires: e2fsprogs-devel
9ec497
BuildRequires: libacl-devel
9ec497
BuildRequires: libattr-devel
9ec497
BuildRequires: openssl-devel
9ec497
BuildRequires: libxml2-devel
9ec497
BuildRequires: automake autoconf libtool
9ec497
9ec497
9ec497
# CVE-2013-0211 libarchive: read buffer overflow on 64-bit systems
9ec497
# https://bugzilla.redhat.com/show_bug.cgi?id=927105
9ec497
Patch0: libarchive-3.1.3-CVE-2013-0211_read_buffer_overflow.patch
9ec497
9ec497
Patch1: libarchive-3.1.2-testsuite.patch
9ec497
9ec497
%description
9ec497
Libarchive is a programming library that can create and read several different
9ec497
streaming archive formats, including most popular tar variants, several cpio
9ec497
formats, and both BSD and GNU ar variants. It can also write shar archives and
9ec497
read ISO9660 CDROM images and ZIP archives.
9ec497
9ec497
%package        devel
9ec497
Summary:        Development files for %{name}
9ec497
Group:          Development/Libraries
9ec497
Requires:       %{name}%{?_isa} = %{version}-%{release}
9ec497
9ec497
%description    devel
9ec497
The %{name}-devel package contains libraries and header files for
9ec497
developing applications that use %{name}.
9ec497
9ec497
9ec497
%package -n     bsdtar
9ec497
Summary:        Manipulate tape archives
9ec497
Group:          Applications/File
9ec497
Requires:       %{name} = %{version}-%{release}
9ec497
9ec497
%description -n bsdtar
9ec497
The bsdtar package contains standalone bsdtar utility split off regular
9ec497
libarchive packages.
9ec497
9ec497
9ec497
%package -n     bsdcpio
9ec497
Summary:        Copy files to and from archives
9ec497
Group:          Applications/File
9ec497
Requires:       %{name} = %{version}-%{release}
9ec497
9ec497
%description -n bsdcpio
9ec497
The bsdcpio package contains standalone bsdcpio utility split off regular
9ec497
libarchive packages.
9ec497
9ec497
9ec497
%prep
9ec497
%setup -q -n %{name}-%{version}
9ec497
%patch0 -p1 -b .CVE-2013-0211
9ec497
# fix bugs in testsuite
9ec497
# ~> upstream ~> 26629c191a & b539b2e597 & 9caa49246
9ec497
%patch1 -p1 -b .fix-testsuite
9ec497
9ec497
9ec497
%build
9ec497
build/autogen.sh
9ec497
%configure --disable-static --disable-rpath
9ec497
# remove rpaths
9ec497
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
9ec497
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
9ec497
9ec497
test -z "$V" && verbose_make="V=1"
9ec497
make %{?_smp_mflags} $verbose_make
9ec497
9ec497
9ec497
%install
9ec497
rm -rf $RPM_BUILD_ROOT
9ec497
make install DESTDIR=$RPM_BUILD_ROOT
9ec497
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
9ec497
9ec497
9ec497
%check
9ec497
run_testsuite()
9ec497
{
9ec497
    LD_LIBRARY_PATH=`pwd`/.libs make check -j1
9ec497
    res=$?
9ec497
    echo $res
9ec497
    if [ $res -ne 0 ]; then
9ec497
        # error happened - try to extract in koji as much info as possible
9ec497
        cat test-suite.log
9ec497
        echo "========================="
9ec497
        err=`cat test-suite.log | grep "Details for failing tests" | cut -d: -f2`
9ec497
        for i in $err; do
9ec497
            find $i -printf "%p\n    ~> a: %a\n    ~> c: %c\n    ~> t: %t\n    ~> %s B\n"
9ec497
            echo "-------------------------"
9ec497
            cat $i/*.log
9ec497
        done
9ec497
        return 1
9ec497
    else
9ec497
        return 0
9ec497
    fi
9ec497
}
9ec497
9ec497
# On a ppc/ppc64 is some race condition causing 'make check' fail on ppc
9ec497
# when both 32 and 64 builds are done in parallel on the same machine in
9ec497
# koji.  Try to run once again if failed.
9ec497
%ifarch ppc
9ec497
run_testsuite || run_testsuite
9ec497
%else
9ec497
run_testsuite
9ec497
%endif
9ec497
9ec497
9ec497
%clean
9ec497
rm -rf $RPM_BUILD_ROOT
9ec497
9ec497
9ec497
%post -p /sbin/ldconfig
9ec497
9ec497
9ec497
%postun -p /sbin/ldconfig
9ec497
9ec497
9ec497
%files
9ec497
%defattr(-,root,root,-)
9ec497
%doc COPYING README NEWS
9ec497
%{_libdir}/libarchive.so.13*
9ec497
%{_mandir}/*/cpio.*
9ec497
%{_mandir}/*/mtree.*
9ec497
%{_mandir}/*/tar.*
9ec497
9ec497
%files devel
9ec497
%defattr(-,root,root,-)
9ec497
%doc
9ec497
%{_includedir}/*.h
9ec497
%{_mandir}/*/archive*
9ec497
%{_mandir}/*/libarchive*
9ec497
%{_libdir}/libarchive.so
9ec497
%{_libdir}/pkgconfig/libarchive.pc
9ec497
9ec497
%files -n bsdtar
9ec497
%defattr(-,root,root,-)
9ec497
%doc COPYING README NEWS
9ec497
%{_bindir}/bsdtar
9ec497
%{_mandir}/*/bsdtar*
9ec497
9ec497
%files -n bsdcpio
9ec497
%defattr(-,root,root,-)
9ec497
%doc COPYING README NEWS
9ec497
%{_bindir}/bsdcpio
9ec497
%{_mandir}/*/bsdcpio*
9ec497
9ec497
9ec497
%changelog
9ec497
* Mon Jul 22 2013 Pavel Raiskup <praiskup@redhat.com> - 3.1.2-5
9ec497
- try to workaround racy testsuite fail
9ec497
9ec497
* Sun Jun 30 2013 Pavel Raiskup <praiskup@redhat.com> - 3.1.2-4
9ec497
- enable testsuite in the %%check phase
9ec497
9ec497
* Mon Jun 24 2013 Pavel Raiskup <praiskup@redhat.com> - 3.1.2-3
9ec497
- bsdtar/bsdcpio should require versioned libarchive
9ec497
9ec497
* Wed Apr  3 2013 Tomas Bzatek <tbzatek@redhat.com> - 3.1.2-2
9ec497
- Remove libunistring-devel build require
9ec497
9ec497
* Thu Mar 28 2013 Tomas Bzatek <tbzatek@redhat.com> - 3.1.2-1
9ec497
- Update to 3.1.2
9ec497
- Fix CVE-2013-0211: read buffer overflow on 64-bit systems (#927105)
9ec497
9ec497
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.1.1-2
9ec497
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
9ec497
9ec497
* Mon Jan 14 2013 Tomas Bzatek <tbzatek@redhat.com> - 3.1.1-1
9ec497
- Update to 3.1.1
9ec497
- NEWS seems to be valid UTF-8 nowadays
9ec497
9ec497
* Wed Oct 03 2012 Pavel Raiskup <praiskup@redhat.com> - 3.0.4-3
9ec497
- better install manual pages for libarchive/bsdtar/bsdcpio (# ... )
9ec497
- several fedora-review fixes ...:
9ec497
- Source0 has moved to github.com
9ec497
- remove trailing white spaces
9ec497
- repair summary to better describe bsdtar/cpiotar utilities
9ec497
9ec497
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.4-2
9ec497
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
9ec497
9ec497
* Mon May  7 2012 Tomas Bzatek <tbzatek@redhat.com> - 3.0.4-1
9ec497
- Update to 3.0.4
9ec497
9ec497
* Wed Feb  1 2012 Tomas Bzatek <tbzatek@redhat.com> - 3.0.3-2
9ec497
- Enable bsdtar and bsdcpio in separate subpackages (#786400)
9ec497
9ec497
* Fri Jan 13 2012 Tomas Bzatek <tbzatek@redhat.com> - 3.0.3-1
9ec497
- Update to 3.0.3
9ec497
9ec497
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.0-0.3.a
9ec497
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
9ec497
9ec497
* Tue Nov 15 2011 Rex Dieter <rdieter@fedoraproject.org> 3.0.0-0.2.a
9ec497
- track files/sonames closer, so abi bumps aren't a surprise
9ec497
- tighten subpkg deps via %%_isa
9ec497
9ec497
* Mon Nov 14 2011 Tomas Bzatek <tbzatek@redhat.com> - 3.0.0-0.1.a
9ec497
- Update to 3.0.0a (alpha release)
9ec497
9ec497
* Mon Sep  5 2011 Tomas Bzatek <tbzatek@redhat.com> - 2.8.5-1
9ec497
- Update to 2.8.5
9ec497
9ec497
* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.8.4-3
9ec497
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
9ec497
9ec497
* Thu Jan 13 2011 Tomas Bzatek <tbzatek@redhat.com> - 2.8.4-2
9ec497
- Rebuild for new xz-libs
9ec497
9ec497
* Wed Jun 30 2010 Tomas Bzatek <tbzatek@redhat.com> - 2.8.4-1
9ec497
- Update to 2.8.4
9ec497
9ec497
* Fri Jun 25 2010 Tomas Bzatek <tbzatek@redhat.com> - 2.8.3-2
9ec497
- Fix ISO9660 reader data type mismatches (#597243)
9ec497
9ec497
* Tue Mar 16 2010 Tomas Bzatek <tbzatek@redhat.com> - 2.8.3-1
9ec497
- Update to 2.8.3
9ec497
9ec497
* Mon Mar  8 2010 Tomas Bzatek <tbzatek@redhat.com> - 2.8.1-1
9ec497
- Update to 2.8.1
9ec497
9ec497
* Fri Feb  5 2010 Tomas Bzatek <tbzatek@redhat.com> - 2.8.0-1
9ec497
- Update to 2.8.0
9ec497
9ec497
* Wed Jan  6 2010 Tomas Bzatek <tbzatek@redhat.com> - 2.7.902a-1
9ec497
- Update to 2.7.902a
9ec497
9ec497
* Fri Aug 21 2009 Tomas Mraz <tmraz@redhat.com> - 2.7.1-2
9ec497
- rebuilt with new openssl
9ec497
9ec497
* Fri Aug  7 2009 Tomas Bzatek <tbzatek@redhat.com> 2.7.1-1
9ec497
- Update to 2.7.1
9ec497
- Drop deprecated lzma dependency, libxz handles both formats
9ec497
9ec497
* Mon Jul 27 2009 Tomas Bzatek <tbzatek@redhat.com> 2.7.0-3
9ec497
- Enable XZ compression format
9ec497
9ec497
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.7.0-2
9ec497
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
9ec497
9ec497
* Tue May 12 2009 Tomas Bzatek <tbzatek@redhat.com> 2.7.0-1
9ec497
- Update to 2.7.0
9ec497
9ec497
* Fri Mar  6 2009 Tomas Bzatek <tbzatek@redhat.com> 2.6.2-1
9ec497
- Update to 2.6.2
9ec497
9ec497
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.6.1-2
9ec497
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
9ec497
9ec497
* Mon Feb 16 2009 Tomas Bzatek <tbzatek@redhat.com> 2.6.1-1
9ec497
- Update to 2.6.1
9ec497
9ec497
* Thu Jan  8 2009 Tomas Bzatek <tbzatek@redhat.com> 2.6.0-1
9ec497
- Update to 2.6.0
9ec497
9ec497
* Mon Dec 15 2008 Tomas Bzatek <tbzatek@redhat.com> 2.5.904a-1
9ec497
- Update to 2.5.904a
9ec497
9ec497
* Tue Dec  9 2008 Tomas Bzatek <tbzatek@redhat.com> 2.5.903a-2
9ec497
- Add LZMA support
9ec497
9ec497
* Mon Dec  8 2008 Tomas Bzatek <tbzatek@redhat.com> 2.5.903a-1
9ec497
- Update to 2.5.903a
9ec497
9ec497
* Tue Jul 22 2008 Tomas Bzatek <tbzatek@redhat.com> 2.5.5-1
9ec497
- Update to 2.5.5
9ec497
9ec497
* Wed Apr  2 2008 Tomas Bzatek <tbzatek@redhat.com> 2.4.17-1
9ec497
- Update to 2.4.17
9ec497
9ec497
* Wed Mar 19 2008 Tomas Bzatek <tbzatek@redhat.com> 2.4.14-1
9ec497
- Initial packaging