]> git.pld-linux.org Git - packages/nagios-plugin-check_rbl.git/blame - nagios-plugin-check_rbl.spec
- updated to 1.2.2
[packages/nagios-plugin-check_rbl.git] / nagios-plugin-check_rbl.spec
CommitLineData
6e4444f9
ER
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
ea66c793 7Summary: Nagios plugin to check if an server is blacklisted in RBL servers
6e4444f9 8Name: nagios-plugin-%{plugin}
eddba0c3
AG
9Version: 1.2.2
10Release: 1
6e4444f9
ER
11License: GPL
12Group: Networking
b62736fd 13Source0: https://trac.id.ethz.ch/projects/nagios_plugins/downloads/%{plugin}-%{version}.tar.gz
eddba0c3 14# Source0-md5: d8d7003a310c165c4238a549b56cc388
6e4444f9 15Source1: %{plugin}.cfg
07d90841 16Source2: %{plugin}.ini
6e4444f9 17URL: https://trac.id.ethz.ch/projects/nagios_plugins/wiki/check_rbl
871773f7
ER
18BuildRequires: perl-ExtUtils-MakeMaker >= 6.42
19BuildRequires: rpm-perlprov >= 4.1-13
6e4444f9 20BuildRequires: sed >= 4.0
6e4444f9
ER
21%if %{with tests}
22BuildRequires: perl-Nagios-Plugin
23BuildRequires: perl-Net-DNS
24BuildRequires: perl-Parallel-Iterator
25BuildRequires: perl-Readonly
26%endif
871773f7 27Requires: nagios-common
6e4444f9
ER
28BuildArch: noarch
29BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31%define _noautoreq 'perl(utils)'
32
33%define _sysconfdir /etc/nagios/plugins
34%define plugindir %{_prefix}/lib/nagios/plugins
35
36%description
ea66c793 37Nagios plugin to check if an server is blacklisted in RBL servers.
6e4444f9
ER
38
39%prep
40%setup -q -n %{plugin}-%{version}
41
ea66c793 42# https://trac.id.ethz.ch/projects/nagios_plugins/ticket/68
6e4444f9 43%{__sed} -i -e '
4012ac6d 44s/use version;\s*//
6e4444f9
ER
45' %{plugin}
46
47%build
48%{__perl} Makefile.PL \
49 INSTALLVENDORSCRIPT=%{plugindir} \
50 INSTALLDIRS=vendor
51
52%{__make}
53%{?with_tests:%{__make} test}
54
55%install
56rm -rf $RPM_BUILD_ROOT
57%{__make} install \
58 DESTDIR=$RPM_BUILD_ROOT
59
60install -d $RPM_BUILD_ROOT%{_sysconfdir}
61cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/%{plugin}.cfg
07d90841 62cp -a %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/%{plugin}.ini
6e4444f9
ER
63
64rm -f $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod
65rm -f $RPM_BUILD_ROOT%{perl_vendorarch}/auto/check_rbl/.packlist
66rm -f $RPM_BUILD_ROOT%{perl_vendorlib}/check_rbl.pod
67
68%clean
69rm -rf $RPM_BUILD_ROOT
70
71%files
72%defattr(644,root,root,755)
73%doc AUTHORS Changes NEWS README INSTALL TODO VERSION
74%attr(640,root,nagios) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{plugin}.cfg
07d90841 75%attr(640,root,nagios) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{plugin}.ini
6e4444f9 76%attr(755,root,root) %{plugindir}/%{plugin}
b9cbc94d 77%{_mandir}/man1/check_rbl.1*
This page took 0.120472 seconds and 4 git commands to generate.