1 |
# This spec is in the SVN |
2 |
# $Id: perl-RPM4.spec 141783 2007-03-12 14:05:45Z nanardon $ |
3 |
|
4 |
%define module RPM4 |
5 |
%define name perl-%{module} |
6 |
%define version 0.23 |
7 |
%define release %mkrel 14 |
8 |
|
9 |
%define rpm_version %(rpm -q --queryformat '%|EPOCH?{[%{EPOCH}:%{VERSION}]}:{%{VERSION}}|' rpm) |
10 |
|
11 |
Name: %{name} |
12 |
Version: %{version} |
13 |
Release: %{release} |
14 |
Summary: Perl bindings to use rpmlib and manage hdlist files |
15 |
License: GPL |
16 |
Group: Development/Perl |
17 |
Source: %{module}-%{version}.tar.gz |
18 |
Patch0: RPM4-fix-build-with-rpm46.patch |
19 |
Patch1: RPM4-0.23-rpm48.patch |
20 |
Url: http://search.cpan.org/dist/RPM4/ |
21 |
|
22 |
BuildRequires: perl-devel >= 5.8.0 |
23 |
BuildRequires: rpm-devel |
24 |
BuildRequires: perl-Digest-SHA1 |
25 |
BuildRequires: librpmconstant-devel |
26 |
BuildRequires: packdrake |
27 |
BuildRequires: perl-MDV-Packdrakeng |
28 |
BuildRequires: gnupg |
29 |
|
30 |
Requires: perl |
31 |
# we can now expect librpm API to be at least backward compatible |
32 |
Requires: rpm >= %{rpm_version} |
33 |
|
34 |
%description |
35 |
This module provides a perl interface to the rpmlib. |
36 |
|
37 |
It allows to write scripts to: |
38 |
- query rpm headers, |
39 |
- query rpm database, |
40 |
- build rpm specs, |
41 |
- install/uninstall specfiles, |
42 |
- check dependencies. |
43 |
|
44 |
It include: |
45 |
- rpm_produced, give what rpm will be produced by a src.rpm or a specfile. |
46 |
|
47 |
%prep |
48 |
%setup -q -n %{module}-%{version} |
49 |
%patch0 -p1 -b .rpm46 |
50 |
%patch1 -p1 |
51 |
|
52 |
%build |
53 |
%{__perl} Makefile.PL INSTALLDIRS=vendor |
54 |
%make |
55 |
|
56 |
%check |
57 |
PERL5DIR=`pwd`/src/blib/arch TMPDIR=/tmp %make test |
58 |
|
59 |
%clean |
60 |
rm -rf $RPM_BUILD_ROOT |
61 |
|
62 |
%install |
63 |
rm -rf $RPM_BUILD_ROOT |
64 |
%makeinstall_std |
65 |
|
66 |
%files |
67 |
%defattr(-,root,root) |
68 |
%doc ChangeLog README |
69 |
%doc examples |
70 |
%_bindir/* |
71 |
%{perl_vendorarch}/* |
72 |
%{_mandir}/*/* |
73 |
|
74 |
|