2006-12-19 00:15:26 +01:00
|
|
|
#
|
2011-08-01 15:24:54 +02:00
|
|
|
# spec file for package bzip2
|
2006-12-19 00:15:26 +01:00
|
|
|
#
|
2012-01-07 21:37:58 +01:00
|
|
|
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2006-12-19 00:15:26 +01:00
|
|
|
#
|
2008-11-01 23:15:35 +01:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2006-12-19 00:15:26 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2008-03-26 16:05:50 +01:00
|
|
|
|
2006-12-19 00:15:26 +01:00
|
|
|
Name: bzip2
|
2010-09-23 23:51:54 +02:00
|
|
|
Version: 1.0.6
|
2011-08-11 09:39:03 +02:00
|
|
|
Release: 11
|
2009-12-11 12:55:53 +01:00
|
|
|
Provides: bzip
|
2006-12-19 00:15:26 +01:00
|
|
|
Obsoletes: bzip
|
2009-12-11 12:55:53 +01:00
|
|
|
BuildRequires: pkg-config
|
2011-10-02 17:39:16 +02:00
|
|
|
BuildRequires: libtool
|
2007-03-30 16:38:08 +02:00
|
|
|
# The following is a kludge to get updating bzip2 to after the split work
|
2007-06-03 21:05:49 +02:00
|
|
|
PreReq: libbz2-1
|
2008-11-01 23:15:35 +01:00
|
|
|
# bug437293
|
|
|
|
%ifarch ppc64
|
|
|
|
Obsoletes: bzip2-64bit
|
|
|
|
%endif
|
|
|
|
#
|
2006-12-19 00:15:26 +01:00
|
|
|
Group: Productivity/Archiving/Compression
|
2012-01-07 21:37:58 +01:00
|
|
|
License: BSD-3-Clause
|
2007-11-08 23:51:26 +01:00
|
|
|
Url: http://www.bzip.org/
|
2006-12-19 00:15:26 +01:00
|
|
|
Summary: A Program for Compressing Files
|
|
|
|
Source: bzip2-%{version}.tar.gz
|
|
|
|
Source1: bznew.gz
|
|
|
|
Source2: bznew.1.gz
|
2009-12-16 08:55:47 +01:00
|
|
|
Source3: baselibs.conf
|
2007-05-25 23:56:09 +02:00
|
|
|
Source100: rpmlintrc
|
2010-11-03 12:56:55 +01:00
|
|
|
# PATCH-FEATURE-OPENSUSE bzip2-1.0.6-autoconfiscated.patch sbrabec@suse.cz -- Convert to a standard autoconf based package.
|
|
|
|
Patch: http://ftp.suse.com/pub/people/sbrabec/bzip2/for_downstream/bzip2-1.0.6-autoconfiscated.patch
|
2007-01-19 12:25:02 +01:00
|
|
|
Patch2: bzip2-maxlen20.patch
|
|
|
|
Patch3: bzip2-faster.patch
|
2008-04-06 02:00:24 +02:00
|
|
|
Patch5: bzip2-unsafe_strcpy.patch
|
2011-08-10 22:25:15 +02:00
|
|
|
Patch6: bzip2-point-to-doc-pkg.patch
|
2012-01-07 21:37:58 +01:00
|
|
|
Patch7: bzip2-ocloexec.patch
|
2006-12-19 00:15:26 +01:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
|
|
|
|
%description
|
2007-11-08 23:51:26 +01:00
|
|
|
The bzip2 program is a very powerful program for compressing files.
|
2006-12-19 00:15:26 +01:00
|
|
|
|
2007-03-23 21:42:21 +01:00
|
|
|
%package doc
|
2012-01-07 21:37:58 +01:00
|
|
|
License: BSD-3-Clause
|
2007-11-08 23:51:26 +01:00
|
|
|
Summary: The bzip2 program and Library Documentation
|
2007-03-23 21:42:21 +01:00
|
|
|
Group: Productivity/Archiving/Compression
|
2009-12-26 11:47:35 +01:00
|
|
|
%if 0%{?suse_version} >= 1120
|
|
|
|
BuildArch: noarch
|
|
|
|
%endif
|
2007-03-23 21:42:21 +01:00
|
|
|
|
|
|
|
%description doc
|
2007-11-08 23:51:26 +01:00
|
|
|
The bzip2 program and library documentation.
|
2007-03-23 21:42:21 +01:00
|
|
|
|
2007-06-03 21:05:49 +02:00
|
|
|
%package -n libbz2-1
|
2012-01-07 21:37:58 +01:00
|
|
|
License: BSD-3-Clause
|
2007-11-08 23:51:26 +01:00
|
|
|
Summary: The bzip2 runtime library
|
2007-03-23 21:42:21 +01:00
|
|
|
Group: Productivity/Archiving/Compression
|
|
|
|
|
2007-06-03 21:05:49 +02:00
|
|
|
%description -n libbz2-1
|
2007-11-08 23:51:26 +01:00
|
|
|
The bzip2 runtime library
|
2007-03-23 21:42:21 +01:00
|
|
|
|
|
|
|
%package -n libbz2-devel
|
2012-01-07 21:37:58 +01:00
|
|
|
License: BSD-3-Clause
|
2007-11-08 23:51:26 +01:00
|
|
|
Summary: The bzip2 runtime library development files
|
|
|
|
Group: Development/Libraries/Other
|
2009-06-12 16:43:48 +02:00
|
|
|
Requires: libbz2-1 = %{version} glibc-devel
|
2007-03-23 21:42:21 +01:00
|
|
|
|
|
|
|
%description -n libbz2-devel
|
2007-11-08 23:51:26 +01:00
|
|
|
The bzip2 runtime library development files.
|
2007-03-23 21:42:21 +01:00
|
|
|
|
2006-12-19 00:15:26 +01:00
|
|
|
%prep
|
|
|
|
%setup -q
|
2010-11-29 16:46:49 +01:00
|
|
|
%patch
|
2006-12-19 00:15:26 +01:00
|
|
|
%patch2
|
|
|
|
%patch3
|
2008-04-06 02:00:24 +02:00
|
|
|
%patch5
|
2011-08-10 22:25:15 +02:00
|
|
|
%patch6 -p1
|
2012-01-07 21:37:58 +01:00
|
|
|
%patch7
|
2006-12-19 00:15:26 +01:00
|
|
|
|
|
|
|
%build
|
2007-05-25 23:56:09 +02:00
|
|
|
profile_bzip2()
|
|
|
|
{
|
|
|
|
tmpfile=$(mktemp)
|
2010-09-21 18:00:48 +02:00
|
|
|
trap "rm -f $tmpfile $tmpfile.bz2" EXIT
|
2007-05-25 23:56:09 +02:00
|
|
|
tar -cjf $tmpfile.bz2 /usr/src || true
|
|
|
|
# time ./bzip2 $tmpfile
|
|
|
|
time ./bzip2 -d < $tmpfile.bz2 > /dev/null
|
|
|
|
}
|
2012-01-07 21:37:58 +01:00
|
|
|
autoreconf -fiv
|
2007-05-25 23:56:09 +02:00
|
|
|
%if %{do_profiling}
|
2009-12-11 12:55:53 +01:00
|
|
|
export CFLAGS="$RPM_OPT_FLAGS %{cflags_profile_generate}"
|
|
|
|
%endif
|
|
|
|
%configure\
|
|
|
|
--libdir=/%{_lib}\
|
|
|
|
--disable-static
|
|
|
|
%if %{do_profiling}
|
2010-09-21 16:03:08 +02:00
|
|
|
make %{?_smp_mflags}
|
2007-05-25 23:56:09 +02:00
|
|
|
profile_bzip2
|
2009-12-11 12:55:53 +01:00
|
|
|
mkdir .libs.save
|
|
|
|
mv .libs/*.gcda .libs.save/
|
2007-05-25 23:56:09 +02:00
|
|
|
make clean
|
2009-12-11 12:55:53 +01:00
|
|
|
mv .libs.save .libs
|
|
|
|
export CFLAGS="$RPM_OPT_FLAGS %{cflags_profile_feedback}"
|
2012-01-07 21:37:58 +01:00
|
|
|
%configure \
|
2009-12-11 12:55:53 +01:00
|
|
|
--libdir=/%{_lib}\
|
|
|
|
--disable-static
|
2007-05-25 23:56:09 +02:00
|
|
|
%endif
|
2010-09-21 16:03:08 +02:00
|
|
|
make %{?_smp_mflags}
|
2006-12-19 00:15:26 +01:00
|
|
|
|
|
|
|
%install
|
2009-12-11 12:55:53 +01:00
|
|
|
%makeinstall pkgconfigdir=%{_libdir}/pkgconfig
|
|
|
|
rm $RPM_BUILD_ROOT/%{_lib}/libbz2.so $RPM_BUILD_ROOT/%{_lib}/libbz2.la
|
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_libdir}
|
|
|
|
ln -sf ../../%{_lib}/libbz2.so.1 $RPM_BUILD_ROOT%{_libdir}/libbz2.so
|
2006-12-19 00:15:26 +01:00
|
|
|
gzip -9 manual.ps
|
|
|
|
gzip -dc %{SOURCE1} > bznew
|
2009-12-11 12:55:53 +01:00
|
|
|
install -D -m 755 bznew $RPM_BUILD_ROOT%{_bindir}/bznew
|
2007-05-25 23:56:09 +02:00
|
|
|
install -m 644 %{SOURCE2} $RPM_BUILD_ROOT%{_mandir}/man1
|
2006-12-19 00:15:26 +01:00
|
|
|
|
2007-06-03 21:05:49 +02:00
|
|
|
%post -n libbz2-1 -p /sbin/ldconfig
|
2006-12-19 00:15:26 +01:00
|
|
|
|
2007-06-03 21:05:49 +02:00
|
|
|
%postun -n libbz2-1 -p /sbin/ldconfig
|
2006-12-19 00:15:26 +01:00
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2007-03-23 21:42:21 +01:00
|
|
|
%doc %{_mandir}/man1/*
|
2006-12-19 00:15:26 +01:00
|
|
|
%{_bindir}/*
|
|
|
|
|
2007-03-23 21:42:21 +01:00
|
|
|
%files doc
|
|
|
|
%defattr(-,root,root)
|
2011-08-10 22:25:15 +02:00
|
|
|
%doc manual.ps.gz manual*.html bzip2.txt manual.pdf
|
2007-03-23 21:42:21 +01:00
|
|
|
|
2007-06-03 21:05:49 +02:00
|
|
|
%files -n libbz2-1
|
2007-03-23 21:42:21 +01:00
|
|
|
%defattr(-,root,root)
|
|
|
|
/%{_lib}/libbz2.so.1
|
|
|
|
/%{_lib}/libbz2.so.1.*
|
|
|
|
|
|
|
|
%files -n libbz2-devel
|
|
|
|
%defattr(-,root,root)
|
2012-01-07 21:37:58 +01:00
|
|
|
%doc LICENSE CHANGES
|
2007-03-23 21:42:21 +01:00
|
|
|
%{_includedir}/bzlib.h
|
|
|
|
%{_libdir}/libbz2.so
|
2009-12-11 12:55:53 +01:00
|
|
|
%{_libdir}/pkgconfig/bzip2.pc
|
2007-12-07 19:52:27 +01:00
|
|
|
|
2007-03-23 21:42:21 +01:00
|
|
|
%changelog
|