Add RPMBDB module

This commit is contained in:
Denis Silakov 2014-01-15 02:33:42 -05:00
parent b850876b67
commit 6775dafed5
2 changed files with 27 additions and 1 deletions

View file

@ -1,3 +1,4 @@
sources:
"cpu-os-macros.tar.gz": 99c5fa561dd0d897bfa8cd97f2aa60781bc578d4
"rpm-5.4.10.tar.gz": 8b525f6762d0a4f3bd5af44971f1199c6805d7dd
RPMBDB-0.1.tar.xz: d56f37fff7f7f8b036b4ce3b06c1ab205687596b

View file

@ -59,7 +59,7 @@ Summary: The RPM package management system
Name: rpm
Epoch: 1
Version: %{libver}.%{minorver}
Release: %{?prereldate:0.%{prereldate}.}21
Release: %{?prereldate:0.%{prereldate}.}22
License: LGPLv2.1+
Group: System/Configuration/Packaging
URL: http://rpm5.org/
@ -75,6 +75,7 @@ Source0: ftp://ftp.jbj.org/pub/rpm-%{libver}.x/%{name}-%{srcver}.tar.gz
Source2: rpm.rpmlintrc
Source3: cpu-os-macros.tar.gz
Source4: legacy_compat.macros
Source5: RPMBDB-0.1.tar.xz
# already merged upstream
Patch0: rpm-5.3.8-set-default-bdb-log-dir.patch
# TODO: should be disable for cooker, packaging needs to be fixed (enable for legacy compatibility)
@ -649,6 +650,14 @@ Requires: perl-IO-String
%description -n perl-%{perlmod}
The RPM Perl module provides an object-oriented interface to querying both
the installed RPM database as well as files on the filesystem.
%package -n perl-RPMBDB
Summary: Perl extension for accessing certain Berkeley DB functionality
Group: Development/Perl
Requires: %{librpmname} = %{EVRD}
%description -n perl-RPMBDB
This perl extension provides certain Berkeley DB functionality used by urpmi.
%endif
%if %{with ruby}
@ -960,11 +969,22 @@ echo '#define PREMACROFILES "%{_sysconfdir}/rpm/premacros.d/*.macros"' >> config
%make apidocs
%endif
%if %{with perl}
pushd RPMBDB-*
perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}" CCCDLFLAGS="-fno-PIE -fPIC"
sed -i -e 's,-fPIC -fno-PIE,-fno-PIE -fPIC,g' ../perl/Makefile.perl
%make
popd
%endif
%check
#make check
%install
%makeinstall_std -k
%if %{with perl}
%makeinstall_std -C RPMBDB-*
%endif
# XXX: why isn't this installed by 'make install'?
install -m755 scripts/symclash.* %{buildroot}%{_rpmhome}
@ -1248,6 +1268,11 @@ ln -f %{buildroot}%{_rpmhome}/bin/{rpmluac,luac}
%dir %{perl_vendorarch}/%{perlmod}
%{perl_vendorarch}/%{perlmod}/*.pm
%{perl_vendorarch}/auto/%{perlmod}
%files -n perl-RPMBDB
%{perl_vendorarch}/RPMBDB.pm
%dir %{perl_vendorarch}/auto/RPMBDB
%{perl_vendorarch}/auto/RPMBDB/RPMBDB.so
%endif
%if %{with python}