# i386 i386
# - python(abi) cap is not provided automatically because /usr/lib*/libpython2*.so.*
# matches ELF first
-# - repackaging when lzma is not installed (todo: fix digest signature of header)
-# rpmbuild computes digest when writing package to temporary file, then adds a few
-# tags (incl. digest) and writes whole package to destination file;
-# repackaging uses unchanged "immutable header" image from original rpm, also
-# preserving payload format and compressor from original rpm, _not_ current settings
# - TODO: add macros for some ppc, mipsel, alpha and sparc
# - uppackaged list:
# /usr/lib/rpm/http.req
# /usr/lib/rpm/vcheck
# /usr/share/man/man8/rpmconstant.8
#
+# - headerGet() making poldek segfault http://rpm5.org/cvs/tktview?tn=38,1
+# - LUA segfault - http://rpm5.org/cvs/tktview?tn=39,1
+# - rpm doesn't exit when no sources/patches available http://rpm5.org/cvs/tktview?tn=40,1
+#
# Conditional build:
%bcond_with static # build static rpm+rpmi
-%bcond_without apidocs # don't generate documentation with doxygen
+%bcond_with apidocs # don't generate documentation with doxygen
%bcond_with autoreqdep # autogenerate package name deps in addition to sonames/perl(X)
%bcond_without python # don't build python bindings
%bcond_without selinux # build without selinux support
Summary(uk.UTF-8): Менеджер пакетів від RPM
Name: rpm
Version: 5.1.4
-Release: 0.3
+Release: 0.8
License: LGPL
Group: Base
Source0: http://rpm5.org/files/rpm/rpm-5.1/%{name}-%{version}.tar.gz
Patch16: %{name}-php-deps.patch
Patch17: %{name}-macros.patch
Patch18: %{name}-macros-th.patch
+Patch19: %{name}-glob.patch
Patch23: %{name}-pkgconfigdeps.patch
Patch35: %{name}-perl_req-INC_dirs.patch
Patch36: %{name}-debuginfo.patch
Patch37: %{name}-doxygen_hack.patch
+Patch38: %{name}-perl_req-use_base.patch
Patch42: %{name}-old-fileconflicts-behaviour.patch
Patch55: %{name}-truncate-cvslog.patch
-Patch58: %{name}-repackage-wo-lzma.patch
Patch59: %{name}-libtool-deps.patch
Patch60: %{name}-mimetype.patch
Patch61: %{name}-sparc64.patch
BuildRequires: elfutils-devel >= 0.108
BuildRequires: gettext-autopoint >= 0.11.4-2
BuildRequires: gettext-devel >= 0.11.4-2
+BuildRequires: lzma-devel >= 4.999.3
BuildRequires: libmagic-devel
%{?with_selinux:BuildRequires: libselinux-devel >= 1.18}
# needed only for AM_PROG_CXX used for CXX substitution in rpm.macros
Conflicts: glibc < 2.2.92
# db4.6 poldek needed
Conflicts: poldek < 0.21-0.20070703.00.3
+# segfaults with lzma 0.42.2
+Conflicts: lzma-libs < 4.999.3
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%define _binary_payload w9.gzdio
Requires: libmagic >= 1.15-2
%{?with_selinux:Requires: libselinux >= 1.18}
Requires: popt >= %{reqpopt_ver}
-%{?with_suggest_tags:Suggests: lzma}
Obsoletes: rpm-libs
# avoid SEGV caused by mixed db versions
Conflicts: poldek < 0.18.1-16
%if %{with suggest_tags}
Suggests: bzip2
Suggests: gzip
-Suggests: lzma
%endif
Conflicts: filesystem-debuginfo < 3.0-16
Requires: glibc-devel
Requires: grep
Requires: gzip
-Requires: lzma
Requires: make
Requires: patch
Requires: sed
%patch35 -p0
%patch36 -p1
%patch37 -p1
+%patch38 -p1
%patch42 -p1
%patch46 -p1
%patch47 -p1
# OLD COMMENTED OUT
#%%patch52 -p1 -- morearchs (rpmrc patch) adds ppc7400, ppc7400
%patch55 -p1
-%patch58 -p1
%patch59 -p1
%patch17 -p1
%patch18 -p1
+%patch19 -p1
%patch60 -p1
%ifarch sparc64
%patch61 -p1
# rpm checks for CPU type at runtime, but it looks better
#sed -i -e 's|@host@|%{_target_cpu}-%{_target_vendor}-linux-gnu|' -e 's|@host_cpu@|%{_target_cpu}|' macros.in
-%{?with_system_lua:CPPFLAGS=-I/usr/include/lua51}
+%{?with_system_lua:CPPFLAGS="-I/usr/include/lua51 %{rpmcppflags}"}
# pass CC and CXX too in case of building with some older configure macro
%configure \
CC="%{__newcc}" \
--with-zlib=external \
--with-bzip2=external \
--with-beecrypt=external \
+ --with-lzma=external \
--with-neon=%{?with_neon:external}%{!?with_neon:no} \
--with-file=external \
--with-popt=external \
# move rpm to /bin
mv $RPM_BUILD_ROOT%{_bindir}/rpm $RPM_BUILD_ROOT/bin
# move essential libs to /lib (libs that /bin/rpm links to)
-for a in librpm-%{sover}.so librpmdb-%{sover}.so librpmio-%{sover}.so librpmbuild-%{sover}.so; do
+for a in librpm-%{sover}.so librpmdb-%{sover}.so librpmio-%{sover}.so librpmbuild-%{sover}.so librpmmisc-%{sover}.so; do
mv -f $RPM_BUILD_ROOT%{_libdir}/$a $RPM_BUILD_ROOT/%{_lib}
ln -s /%{_lib}/$a $RPM_BUILD_ROOT%{_libdir}/$a
done
#%attr(755,root,root) %{_bindir}/rpmsign
#%attr(755,root,root) %{_bindir}/rpmverify
-%dir %{_sysconfdir}/rpm
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rpm/macros
%dir %{_sysconfdir}/rpm/sysinfo
# these are ok to be replaced
%files base
%defattr(644,root,root,755)
+%dir %{_sysconfdir}/rpm
%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rpm
%dir %{_rpmlibdir}
%attr(755,root,root) %{_bindir}/banner.sh
%attr(755,root,root) /%{_lib}/librpmdb-%{sover}.so
%attr(755,root,root) /%{_lib}/librpmio-%{sover}.so
%attr(755,root,root) /%{_lib}/librpmbuild-%{sover}.so
+%attr(755,root,root) /%{_lib}/librpmmisc-%{sover}.so
%files devel
%defattr(644,root,root,755)