]> git.pld-linux.org Git - packages/perl-Mail-SPF-Query.git/blob - perl-Mail-SPF-Query.spec
- drop obsolete and outdated manual inclusion of rpm macros
[packages/perl-Mail-SPF-Query.git] / perl-Mail-SPF-Query.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # do not perform "make test"
4 #
5 %define         pdir    Mail
6 %define         pnam    SPF-Query
7 Summary:        Mail::SPF::Query - Perl implementation of SPF
8 Summary(pl.UTF-8):      Mail::SPF::Query - perlowa implementacja SPF
9 Name:           perl-Mail-SPF-Query
10 Version:        1.999.1
11 Release:        2
12 # same as perl
13 License:        GPL v1+ or Artistic
14 Group:          Development/Languages/Perl
15 Source0:        http://www.cpan.org/modules/by-module/Mail/%{pdir}-%{pnam}-%{version}.tar.gz
16 # Source0-md5:  6d62d024d1614fa1fa4f43bd39ee7bf0
17 Source1:        spfd.init
18 URL:            http://search.cpan.org/dist/Mail-SPF-Query/
19 %if %{with tests}
20 BuildRequires:  perl-Net-CIDR-Lite >= 0.15
21 BuildRequires:  perl-Net-DNS >= 0.33
22 BuildRequires:  perl-Sys-Hostname-Long
23 BuildRequires:  perl-Test-Simple
24 BuildRequires:  perl-URI
25 %endif
26 BuildRequires:  perl-devel >= 1:5.8.0
27 BuildRequires:  rpm-perlprov >= 4.1-13
28 BuildRequires:  rpmbuild(macros) >= 1.268
29 Requires:       perl(URI::Escape) >= 3.20
30 Requires:       perl-Net-CIDR-Lite >= 0.15
31 Requires:       perl-Net-DNS >= 0.33
32 Requires:       perl-Sys-Hostname-Long
33 BuildArch:      noarch
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 %description
37 This module implements a daemon to query SPF records for email forgery
38 detection.
39
40 %description -l pl.UTF-8
41 Ten moduł jest implementacją demona sprawdzającego rekordy SPF w celu
42 wykrywania sfałszowanej poczty.
43
44 %package -n spfd
45 Summary:        SPF record checking daemon
46 Summary(pl.UTF-8):      Demon sprawdzający rekordy SPF
47 Group:          Networking/Daemons
48 Requires(post,preun):   /sbin/chkconfig
49 Requires:       %{name} = %{version}-%{release}
50 Requires:       rc-scripts
51
52 %description -n spfd
53 SPF record checking daemon, operating as a local resolver on
54 UNIX-domain sockets.
55
56 %description -n spfd -l pl.UTF-8
57 Demon sprawdzający rekordy SPF, działający jako lokalny resolver na
58 gniazdach uniksowych.
59
60 %prep
61 %setup -q -n %{pdir}-%{pnam}-%{version}
62
63 %build
64 %{__perl} Makefile.PL \
65         INSTALLDIRS=vendor
66 %{__make}
67
68 %{?with_tests:%{__make} test}
69
70 %install
71 rm -rf $RPM_BUILD_ROOT
72 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
73
74 %{__make} install \
75         DESTDIR=$RPM_BUILD_ROOT
76
77 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/spfd
78
79 # we prefer spfquery from perl-Mail-SPF
80 rm -rf $RPM_BUILD_ROOT{%{_bindir}/spfquery,%{_mandir}/man1/spfquery*}
81
82 %clean
83 rm -rf $RPM_BUILD_ROOT
84
85 %post -n spfd
86 /sbin/chkconfig --add spfd
87 %service spfd restart "SPF daemon"
88
89 %preun -n spfd
90 if [ "$1" = "0" ]; then
91         %service spfd stop
92         /sbin/chkconfig --del spfd
93 fi
94
95 %files
96 %defattr(644,root,root,755)
97 %doc CHANGES README examples
98 %dir %{perl_vendorlib}/Mail/SPF
99 %{perl_vendorlib}/Mail/SPF/*.pm
100 %{_mandir}/man3/*
101
102 %files -n spfd
103 %defattr(644,root,root,755)
104 %attr(755,root,root) %{_bindir}/spfd
105 %attr(754,root,root) /etc/rc.d/init.d/spfd
106 %{_mandir}/man1/spfd*
This page took 0.06652 seconds and 4 git commands to generate.