]> git.pld-linux.org Git - packages/nagios-plugin-check_rbl.git/blob - nagios-plugin-check_rbl.spec
up to 1.3.1, disable embedded Perl
[packages/nagios-plugin-check_rbl.git] / nagios-plugin-check_rbl.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # do not perform "make test"
4
5 %include        /usr/lib/rpm/macros.perl
6 %define         plugin  check_rbl
7 Summary:        Nagios plugin to check if an server is blacklisted in RBL servers
8 Name:           nagios-plugin-%{plugin}
9 Version:        1.3.1
10 Release:        1
11 License:        GPL v3
12 Group:          Networking
13 Source0:        https://trac.id.ethz.ch/projects/nagios_plugins/downloads/%{plugin}-%{version}.tar.gz
14 # Source0-md5:  220ea65daab4f65b5dc5d3d1fd0d23f5
15 Source1:        %{plugin}.cfg
16 Source2:        %{plugin}.ini
17 URL:            https://trac.id.ethz.ch/projects/nagios_plugins/wiki/check_rbl
18 BuildRequires:  perl-ExtUtils-MakeMaker >= 6.42
19 BuildRequires:  rpm-perlprov >= 4.1-13
20 BuildRequires:  sed >= 4.0
21 %if %{with tests}
22 BuildRequires:  perl-Nagios-Plugin >= 0.31
23 BuildRequires:  perl-Net-DNS
24 BuildRequires:  perl-Readonly
25 %endif
26 Requires:       nagios-common
27 BuildArch:      noarch
28 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30 %define         _sysconfdir     /etc/nagios/plugins
31 %define         plugindir       %{_prefix}/lib/nagios/plugins
32
33 %description
34 Nagios plugin to check if an server is blacklisted in RBL servers.
35
36 %prep
37 %setup -q -n %{plugin}-%{version}
38
39 %build
40 %{__perl} Makefile.PL \
41         INSTALLVENDORSCRIPT=%{plugindir} \
42         INSTALLDIRS=vendor
43
44 %{__make}
45 %{?with_tests:%{__make} test}
46
47 %install
48 rm -rf $RPM_BUILD_ROOT
49 %{__make} install \
50         DESTDIR=$RPM_BUILD_ROOT
51
52 install -d $RPM_BUILD_ROOT%{_sysconfdir}
53 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/%{plugin}.cfg
54 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/%{plugin}.ini
55
56 %{__rm} $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod
57 %{__rm} $RPM_BUILD_ROOT%{perl_vendorarch}/auto/check_rbl/.packlist
58 %{__rm} $RPM_BUILD_ROOT%{perl_vendorlib}/check_rbl.pod
59
60 %clean
61 rm -rf $RPM_BUILD_ROOT
62
63 %files
64 %defattr(644,root,root,755)
65 %doc AUTHORS Changes NEWS README INSTALL TODO VERSION
66 %attr(640,root,nagios) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{plugin}.cfg
67 %attr(640,root,nagios) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{plugin}.ini
68 %attr(755,root,root) %{plugindir}/%{plugin}
69 %{_mandir}/man1/check_rbl.1*
This page took 0.074051 seconds and 3 git commands to generate.