X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=rpm.spec;h=2e08d2caf936fd208841a2e27eaf7ba8fcb7818e;hb=290c1c301f6c440b7985cd079a30c2d0a0da1a7f;hp=cf6bca9d22904c92c1619253daacb070735d344c;hpb=015862ea95f39f156848241d2b68b5b71d9ba68f;p=packages%2Frpm.git diff --git a/rpm.spec b/rpm.spec index cf6bca9..2e08d2c 100644 --- a/rpm.spec +++ b/rpm.spec @@ -1,19 +1,35 @@ +# +# TODO: +# - learn find-perl-provides to use the __perl macro instead +# of /usr/bin/perl +# +# Conditional build: +# _without_static - build shared /bin/rpm (doesn't work at the moment) +# 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" +# %include /usr/lib/rpm/macros.python %define beecrypt_ver 2.2.0 -%define beecrypt_rel 2 +# versions of required libraries +%define reqdb_ver 4.1.25-1 +%define reqpopt_ver 1.7 Summary: RPM Package Manager Summary(de): RPM Packet-Manager Summary(es): Gestor de paquetes RPM Summary(pl): Aplikacja do zarz±dzania pakietami RPM Summary(pt_BR): Gerenciador de pacotes RPM -Summary(ru): íÅÎÅÄÖÅÒ ÐÁËÅÔÏ× ÏÔ Red Hat -Summary(uk): íÅÎÅÄÖÅÒ ÐÁËÅÔ¦× ×¦Ä Red Hat +Summary(ru): íÅÎÅÄÖÅÒ ÐÁËÅÔÏ× ÏÔ RPM +Summary(uk): íÅÎÅÄÖÅÒ ÐÁËÅÔ¦× ×¦Ä RPM Name: rpm -Version: 4.1 -Release: 8 +%define ver 4.2 +Version: %{ver} +%define rel 0.1 +Release: %{rel} +%define beecrypt_rel %{ver}_%{rel} License: GPL Group: Base -Source0: ftp://ftp.rpm.org/pub/rpm/dist/rpm-4.1.x/%{name}-%{version}.tar.gz +Source0: ftp://ftp.rpm.org/pub/rpm/test-4.2/%{name}-%{version}.tar.gz Source1: %{name}.groups Source2: %{name}.macros Source3: %{name}-install-tree @@ -37,6 +53,7 @@ Source20: %{name}-find-php-requires Source30: builder Source31: adapter.awk Source32: pldnotify.awk +Source33: perl.prov Patch0: %{name}-pl.po.patch Patch1: %{name}-%{name}rc.patch Patch2: %{name}-arch.patch @@ -52,9 +69,8 @@ Patch11: %{name}-noexpand.patch Patch12: %{name}-scripts-closefds.patch Patch13: %{name}-python-macros.patch Patch14: %{name}-perlprov-regonly.patch -Patch15: %{name}-4.1-branch.patch Patch16: %{name}-drop-legacy-CLI.patch -Patch17: %{name}-perlprov-perl5.6.patch +Patch15: %{name}-4.1-branch.patch Patch18: %{name}-gettext-in-header.patch Patch19: %{name}-compress-doc.patch Patch20: %{name}-lt14d.patch @@ -66,30 +82,36 @@ Patch25: %{name}-bb-and-short-circuit.patch Patch26: %{name}-4.1-branch-po-updates.patch Patch27: %{name}-link.patch Patch28: %{name}-beecrypt-opt.patch +Patch29: %{name}-python-pic.patch +Patch30: %{name}-home_etc.patch +Patch31: %{name}-system_libs-more.patch +Patch32: %{name}-nofile.patch URL: http://www.rpm.org/ Icon: rpm.gif BuildRequires: autoconf >= 2.52 BuildRequires: automake BuildRequires: bzip2-devel >= 1.0.1 -BuildRequires: db-devel >= 4.1.24-4 +BuildRequires: db-devel >= %{reqdb_ver} BuildRequires: doxygen BuildRequires: gettext-devel >= 0.11.4-2 -BuildRequires: libelf-devel +BuildRequires: elfutils-devel +BuildRequires: libmagic-devel BuildRequires: libtool BuildRequires: patch >= 2.2 BuildRequires: python-devel >= 2.2 BuildRequires: python-modules >= 2.2 BuildRequires: rpm-pythonprov BuildRequires: zlib-devel -BuildRequires: popt-devel >= 1.7 +BuildRequires: popt-devel >= %{reqpopt_ver} %if %{!?_without_static:1}%{?_without_static:0} # Require static library only for static build BuildRequires: bzip2-static >= 1.0.2-5 -BuildRequires: db-static >= 4.1 +BuildRequires: db-static >= %{reqdb_ver} BuildRequires: glibc-static >= 2.2.94 -BuildRequires: libelf-static +BuildRequires: elfutils-static +BuildRequires: libmagic-devel BuildRequires: zlib-static -BuildRequires: popt-static >= 1.7 +BuildRequires: popt-static >= %{reqpopt_ver} %endif BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) Conflicts: glibc < 2.2.92 @@ -100,6 +122,11 @@ Conflicts: glibc < 2.2.92 # don't require very fresh rpm.macros to build %define __gettextize gettextize --copy --force --intl ; cp -f po/Makevars{.template,} +# stabilize new build environment +%define __cc %{?force_cc}%{!?force_cc:%{_target_cpu}-pld-linux-gcc} +%define __cxx %{?force_cxx}%{!?force_cxx:%{_target_cpu}-pld-linux-g++} +%define __cpp %{?force_cpp}%{!?force_cpp:%{_target_cpu}-pld-linux-gcc -E} + %description RPM is a powerful package manager, which can be used to build, install, query, verify, update, and uninstall individual software @@ -159,7 +186,6 @@ Summary(ru): Summary(uk): èÅÄÅÒÉ ÔÁ ¦Â̦ÏÔÅËÉ ÄÌÑ ÐÒÏÇÒÁÍ, ÝÏ ÐÒÁÃÀÀÔØ Ú ÐÁËÅÔÁÍÉ rpm Group: Development/Libraries Requires: %{name} = %{version} -Requires: beecrypt-devel Requires: bzip2-devel Requires: db-devel Requires: libelf-devel @@ -218,6 +244,11 @@ Summary(ru): Summary(uk): óÔÁÔÉÞÎÁ ¦Â̦ÏÔÅËÁ ÄÌÑ ÐÒÏÇÒÁÍ, ÝÏ ÐÒÁÃÀÀÔØ Ú ÐÁËÅÔÁÍÉ rpm Group: Development/Libraries Requires: %{name}-devel = %{version} +Requires: bzip2-static +Requires: db-static +Requires: libelf-static +Requires: popt-static >= 1.7 +Requires: zlib-static %description static RPM static libraries. @@ -264,6 +295,7 @@ Summary(de): Zusatzwerkzeuge f Summary(pl): Dodatkowe narzêdzia do sprawdzenia zale¿no¶ci skryptów perla w pakietach rpm Group: Applications/File Requires: %{name} = %{version} +Requires: perl-devel Requires: perl-modules %description perlprov @@ -340,46 +372,49 @@ Python para manipular pacotes e bancos de dados RPM. %package lib Summary: RPMs library -Summary(pl): Biblioteki RPMa +Summary(pl): Biblioteki RPM-a Group: Libraries +Requires: db >= %{reqdb_ver} +Requires: popt >= %{reqpopt_ver} %description lib RPMs library. %description lib -l pl -Biblioteki RPMa. +Biblioteki RPM-a. %package build -Summary: Scripts for building binary RPM packages -Summary(de): Scripts fürs Bauen binärer RPM-Pakete -Summary(pl): Skrypty pomocnicze do budowania binarnych RPM-ów -Summary(pt_BR): Scripts e programas executáveis usados para construir pacotes +Summary: Scripts for building binary RPM packages +Summary(de): Scripts fürs Bauen binärer RPM-Pakete +Summary(pl): Skrypty pomocnicze do budowania binarnych RPM-ów +Summary(pt_BR): Scripts e programas executáveis usados para construir pacotes Summary(ru): óËÒÉÐÔÙ É ÕÔÉÌÉÔÙ, ÎÅÏÂÈÏÄÉÍÙÅ ÄÌÑ ÓÂÏÒËÉ ÐÁËÅÔÏ× Summary(uk): óËÒÉÐÔÉ ÔÁ ÕÔÉ̦ÔÉ, ÎÅÏÂȦÄΦ ÄÌÑ ÐÏÂÕÄÏ×É ÐÁËÅÔ¦× -Group: Applications/File -Requires: %{name} = %{version} -Requires: /bin/id -Requires: awk -Requires: binutils -Requires: diffutils -Requires: file >= 3.31 -Requires: fileutils -Requires: findutils +Group: Applications/File +Requires(pre): findutils +Requires: %{name} = %{version} +Requires: /bin/id +Requires: awk +Requires: binutils +Requires: diffutils +Requires: file >= 3.31 +Requires: fileutils +Requires: findutils %ifarch athlon -Requires: gcc >= 3.0.3 +Requires: gcc >= 3.0.3 %else -Requires: gcc +Requires: gcc %endif -Requires: glibc-devel -Requires: grep -Requires: gzip -Requires: make -Requires: patch -Requires: popt >= 1.7 -Requires: sed -Requires: sh-utils -Requires: tar -Requires: textutils +Requires: glibc-devel +Requires: grep +Requires: gzip +Requires: make +Requires: patch +Requires: popt >= 1.7 +Requires: sed +Requires: sh-utils +Requires: tar +Requires: textutils %description build Scripts for building binary RPM packages. @@ -482,9 +517,12 @@ Statyczna wersja biblioteki kryptograficznej. %prep %setup -q -%patch0 -p1 +# need update +#%%patch0 -p1 %patch1 -p1 %patch2 -p1 +# find-spec-bcond need update +# po/pl.po need update %patch3 -p1 %patch4 -p1 %patch5 -p1 @@ -501,20 +539,24 @@ Statyczna wersja biblioteki kryptograficznej. %patch12 -p1 %patch13 -p1 %patch14 -p1 -%patch15 -p1 %patch16 -p1 -%patch17 -p1 %patch18 -p1 %patch19 -p1 %patch20 -p1 %patch21 -p1 %patch22 -p1 -%patch23 -p1 +# need review +#%%patch23 -p1 %patch24 -p1 %patch25 -p1 -%patch26 -p1 +# need review +#%%patch26 -p1 %patch27 -p1 %patch28 -p1 +%patch29 -p1 +%patch30 -p1 +%patch31 -p1 +%patch32 -p1 sed -e 's/^/@pld@/' %{SOURCE2} >>platform.in cp -f platform.in macros.pld.in @@ -528,6 +570,7 @@ install %{SOURCE17} scripts/php.prov.in install %{SOURCE18} scripts/php.req.in install %{SOURCE19} scripts/find-php-provides install %{SOURCE20} scripts/find-php-requires +install %{SOURCE33} scripts/perl.prov cd scripts; mv -f perl.req perl.req.in @@ -554,6 +597,7 @@ rm -f missing %{__automake} cd .. + rm -f missing %{__libtoolize} %{__gettextize} @@ -568,7 +612,9 @@ sed -e 's|@host@|%{_target_cpu}-%{_target_vendor}-linux-gnu|' \ -e 's|@host_cpu@|%{_target_cpu}|' macros.in > macros.tmp mv -f macros.tmp macros.in +# pass CC and CXX too in case of building with some older configure macro %configure \ + CC="%{__cc}" CXX="%{__cxx}" CPP="%{__cpp}" \ --enable-shared \ --enable-static \ --with-apidocs \ @@ -615,6 +661,9 @@ cat > $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros <