X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=rpm.spec;h=1760001c4da41131dcdb52df9952d0ede499ac6a;hb=7dbb34ee2a8d8ba76f5244a89aa00eb54e605722;hp=189bb3ea5170e03d8e44926c0f2f0d38f44066d8;hpb=ba7bedbbb16a477c856ea72338dd30f345c17676;p=packages%2Frpm.git diff --git a/rpm.spec b/rpm.spec index 189bb3e..1760001 100644 --- a/rpm.spec +++ b/rpm.spec @@ -1,5 +1,7 @@ # # TODO: +# - make key infrastructure code fallback from keyutils to plain mode in case keyctl +# returns -ENOSYS # - add macros for some ppc, mipsel, alpha and sparc # # - when adopting, use 4.5 ticket for checklist: https://bugs.launchpad.net/pld-linux/+bug/262985 @@ -10,11 +12,12 @@ %bcond_without python # don't build python bindings %bcond_without selinux # build without selinux support %bcond_without suggest_tags # build without Suggest tag (bootstrapping) -%bcond_without neon # build with HTTP/WebDAV support (neon library) +%bcond_with neon # build with HTTP/WebDAV support (neon library) %bcond_without db # BerkeleyDB %bcond_without sqlite # build with SQLite support %bcond_with sqlite_dbapi # default database backend is sqlite -%bcond_without system_lua # use system lua +%bcond_with system_lua # use system lua +%bcond_with keyutils # build with keyutils support # force_cc - force using __cc other than "%{_target_cpu}-pld-linux-gcc" # force_cxx - force using __cxx other than "%{_target_cpu}-pld-linux-g++" # force_cpp - force using __cpp other than "%{_target_cpu}-pld-linux-gcc -E" @@ -34,6 +37,7 @@ ERROR %endif # versions of required libraries +%define reqdb_pkg db5.3 %define reqdb_ver 5.3 %define reqpopt_ver 1.15 %define beecrypt_ver 2:4.1.2-4 @@ -48,7 +52,7 @@ Summary(ru.UTF-8): Менеджер пакетов от RPM Summary(uk.UTF-8): Менеджер пакетів від RPM Name: rpm Version: 5.4.10 -Release: 2 +Release: 22 License: LGPL Group: Base # http://rpm5.org/files/rpm/rpm-5.4/rpm-5.4.10-0.20120706.src.rpm @@ -84,6 +88,7 @@ Source23: rpm.noautoreqdep Source24: rpm.noautoreqfiles Source25: %{name}-php-requires.php Source26: rpmdb_checkversion.c +Source27: macros.lang Patch0: %{name}-branch.patch Patch1: %{name}-man_pl.patch Patch2: %{name}-popt-aliases.patch @@ -132,6 +137,12 @@ Patch44: %{name}-missing-patch-file-fails-build.patch Patch45: %{name}-remove-misleading-missing-patch-message.patch Patch46: %{name}-file-magic-can-be-mixed-case.patch Patch47: %{name}-query-file-always-noisy.patch +Patch48: %{name}-verify-ghosts-broken-logic.patch +Patch49: %{name}-python-enable-compat-RPMSENSE.patch +Patch50: %{name}-dont-treat-gstreamer-modules-as-font.patch +Patch51: %{name}-gst-inspect-typo.patch +Patch52: %{name}-null-term-ascii-digest.patch +Patch53: %{name}-lua-enable-extra-libs.patch # Patches imported from Mandriva @@ -235,6 +246,8 @@ Patch1037: rpm-5.4.10-fix-neon-saving-error-pages-as-target-file.patch Patch1038: rpm-5.4.10-support-ignore-arch-and-os-again.patch # status: ready for merge Patch1039: rpm-5.4.4-fix-same-package-with-epoch-possible-to-upgrade.patch +# we want that patch too, a bit of builder infrastructure relies on NOSIGNATURES +Patch1040: rpm-5.4.9-support-signatures-and-digest-disablers.patch URL: http://rpm5.org/ BuildRequires: autoconf >= 2.60 @@ -245,9 +258,13 @@ BuildRequires: bzip2-devel >= 1.0.2-17 BuildRequires: elfutils-devel >= 0.108 #BuildRequires: gettext-autopoint >= 0.11.4-2 BuildRequires: gettext-devel >= 0.11.4-2 -BuildRequires: keyutils-devel +%{?with_keyutils:BuildRequires: keyutils-devel} BuildRequires: libmagic-devel -%{?with_selinux:BuildRequires: libselinux-devel >= 1.18} +%if %{with selinux} +BuildRequires: libselinux-devel >= 2.1.0 +BuildRequires: libsepol-devel >= 2.1.0 +BuildRequires: libsemanage-devel >= 2.1.0 +%endif # needed only for AM_PROG_CXX used for CXX substitution in rpm.macros BuildRequires: libstdc++-devel BuildRequires: libtool >= 1:1.4.2-9 @@ -276,11 +293,15 @@ BuildRequires: tetex-pdftex # Require static library only for static build BuildRequires: beecrypt-static >= %{beecrypt_ver} BuildRequires: bzip2-static >= 1.0.2-17 -%{?with_db:BuildRequires: db-static >= %{reqdb_ver}} +%{?with_db:BuildRequires: %{reqdb_pkg}-static >= %{reqdb_ver}} BuildRequires: elfutils-static BuildRequires: glibc-static >= 2.2.94 BuildRequires: libmagic-static -%{?with_selinux:BuildRequires: libselinux-static >= 1.18} +%if %{with selinux} +BuildRequires: libselinux-static >= 2.1.0 +BuildRequires: libsepol-static >= 2.1.0 +BuildRequires: libsemanage-static >= 2.1.0 +%endif BuildRequires: popt-static >= %{reqpopt_ver} BuildRequires: zlib-static %endif @@ -392,9 +413,9 @@ Summary: RPMs library Summary(pl.UTF-8): Biblioteki RPM-a Group: Libraries Requires: beecrypt >= %{beecrypt_ver} -%{?with_db:Requires: db >= %{reqdb_ver}} +%{?with_db:Requires: %{reqdb_pkg} >= %{reqdb_ver}} Requires: libmagic >= 1.15-2 -%{?with_selinux:Requires: libselinux >= 1.18} +%{?with_selinux:Requires: libselinux >= 2.1.0} Requires: popt >= %{reqpopt_ver} %{?with_sqlite:Requires: sqlite3 >= %{sqlite_build_version}} Obsoletes: rpm-libs @@ -419,9 +440,9 @@ Group: Development/Libraries Requires: %{name}-lib = %{version}-%{release} Requires: beecrypt-devel >= %{beecrypt_ver} Requires: bzip2-devel -%{?with_db:Requires: db-devel >= %{reqdb_ver}} +%{?with_db:Requires: %{reqdb_pkg}-devel >= %{reqdb_ver}} Requires: elfutils-devel -Requires: keyutils-devel +%{?with_keyutils:Requires: keyutils-devel} Requires: libmagic-devel %{?with_selinux:Requires: libselinux-devel} Requires: popt-devel >= %{reqpopt_ver} @@ -483,9 +504,9 @@ Group: Development/Libraries Requires: %{name}-devel = %{version}-%{release} Requires: beecrypt-static >= %{beecrypt_ver} Requires: bzip2-static -%{?with_db:Requires: db-static >= %{reqdb_ver}} +%{?with_db:Requires: %{reqdb_pkg}-static >= %{reqdb_ver}} Requires: elfutils-static -Requires: keyutils-static +%{?with_keyutils:Requires: keyutils-static} Requires: libmagic-static Requires: popt-static >= %{reqpopt_ver} Requires: zlib-static @@ -803,6 +824,12 @@ Dokumentacja API RPM-a oraz przewodniki w formacie HTML generowane ze %patch45 -p1 %patch46 -p1 %patch47 -p1 +%patch48 -p1 +%patch49 -p1 +%patch50 -p1 +%patch51 -p1 +%patch52 -p0 +%patch53 -p1 %patch1000 -p1 %patch1001 -p1 @@ -844,6 +871,7 @@ Dokumentacja API RPM-a oraz przewodniki w formacie HTML generowane ze %patch1037 -p1 %patch1038 -p1 %patch1039 -p1 +%patch1040 -p1 install %{SOURCE2} macros/pld.in install %{SOURCE8} scripts/php.prov.in @@ -879,12 +907,15 @@ sed -i \ CXX="%{__newcxx}" \ CPP="%{__newcpp}" \ WITH_PERL_VERSION=no \ + __GST_INSPECT=%{_bindir}/gst-inspect-1.0 \ --enable-shared \ --enable-static \ %{!?with_apidocs:--without-apidocs} \ %{?with_python:--with-python=%{py_ver} --with-python-lib-dir=%{py_sitedir}} \ %{!?with_python:--without-python} \ - --with%{!?with_selinux:out}-selinux \ + --with-selinux=%{!?with_selinux:no}%{?with_selinux:external} \ + --with-sepol=%{!?with_selinux:not}%{?with_selinux:external} \ + --with-semanage=%{!?with_selinux:no}%{?with_selinux:external} \ --with-libelf \ --with-zlib=external \ --with-bzip2=external \ @@ -899,7 +930,7 @@ sed -i \ --with-dbapi=%{!?with_sqlite_dbapi:db}%{?with_sqlite_dbapi:sqlite} \ --with-lua=%{!?with_system_lua:internal}%{?with_system_lua:external} \ --with-pcre=external \ - --with-keyutils=none \ + --with-keyutils=%{?with_keyutils:external}%{!?with_keyutils:no} \ --with-uuid=%{_libdir}:%{_includedir}/ossp-uuid \ --without-path-versioned \ --with-extra-path-macros='%{_sysconfdir}/rpm/macros.d/*.macros:%{_rpmlibdir}/macros.d/pld:%{_rpmlibdir}/macros.build:~/etc/.rpmmacros:~/.rpmmacros' \ @@ -1061,6 +1092,7 @@ install %{SOURCE15} $RPM_BUILD_ROOT%{_bindir}/banner.sh install -d $RPM_BUILD_ROOT%{_sysconfdir}/rpm/sysinfo install %{SOURCE18} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros +install %{SOURCE27} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros.lang install %{SOURCE19} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/noautocompressdoc install %{SOURCE20} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/noautoprov install %{SOURCE21} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/noautoprovfiles @@ -1166,6 +1198,7 @@ find %{_rpmlibdir} -name '*-linux' -type l | xargs rm -f %attr(755,root,root) /bin/rpm %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rpm/macros +%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rpm/macros.lang %dir %{_sysconfdir}/rpm/sysinfo # these are ok to be replaced %config %verify(not md5 mtime size) %{_sysconfdir}/rpm/sysinfo/* @@ -1263,7 +1296,17 @@ find %{_rpmlibdir} -name '*-linux' -type l | xargs rm -f %attr(755,root,root) %{_rpmlibdir}/bin/rpmcmp %attr(755,root,root) %{_rpmlibdir}/bin/rpmdeps %attr(755,root,root) %{_rpmlibdir}/bin/rpmdigest -%attr(755,root,root) %{_rpmlibdir}/bin/rpmkey +%if %{with selinux} +%attr(755,root,root) %{_rpmlibdir}/bin/semodule +%attr(755,root,root) %{_rpmlibdir}/bin/spooktool +%endif +%if %{without system_lua} +%attr(755,root,root) %{_rpmlibdir}/bin/lua +%attr(755,root,root) %{_rpmlibdir}/bin/luac +%attr(755,root,root) %{_rpmlibdir}/bin/rpmlua +%attr(755,root,root) %{_rpmlibdir}/bin/rpmluac +%endif +%{?with_keyutils:%attr(755,root,root) %{_rpmlibdir}/bin/rpmkey} %attr(755,root,root) %{_rpmlibdir}/bin/rpmrepo %{_mandir}/man8/rpm2cpio.8* %{_mandir}/man8/rpmcache.8*