#
# Conditional build:
-%bcond_without tests # do not perform "make test"
-#
-%include /usr/lib/rpm/macros.perl
+%bcond_without tests # do not perform "make test"
+
%define pdir Nagios
%define pnam Object
-Summary: Nagios::Object - Perl objects to represent Nagios objects
-Summary(pl): Nagios::Object - obiekty Perla reprezentuj±ce obiekty Nagiosa
+Summary: Nagios::Object - Creates perl objects to represent Nagios objects
+Summary(pl.UTF-8): Nagios::Object - obiekty Perla reprezentujące obiekty Nagiosa
Name: perl-Nagios-Object
-Version: 0.08
+Version: 0.21.20
Release: 1
License: GPL
Group: Development/Languages/Perl
-Source0: http://www.cpan.org/modules/by-authors/id/T/TO/TOBEYA/%{pdir}-%{pnam}-%{version}.tar.gz
-# Source0-md5: 59cf6e6286abcd26674b4da092e4759b
+Source0: http://search.cpan.org/CPAN/authors/id/D/DU/DUNCS/Nagios-Object-%{version}.tar.gz
+# Source0-md5: 6ece5aff7095bb35192a034c8e788d77
URL: http://search.cpan.org/dist/Nagios-Object/
+BuildRequires: perl-Module-Build
BuildRequires: perl-devel >= 1:5.8.0
BuildRequires: rpm-perlprov >= 4.1-13
+%if %{with tests}
+BuildRequires: perl-List-Compare
+BuildRequires: perl-Test-Exception >= 0.01
+BuildRequires: perl-Test-NoWarnings >= 0.08
+%endif
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
at compile-time, so it's pretty trivial to add new attributes or even
entire objects.
-%description -l pl
-Ten modu³ zawiera kod do tworzenia obiektów Perla reprezentuj±cych
-dowolne obiekty Nagiosa. Wszystkie klasy Perla s± generowane
-automatycznie w czasie kompilacji, wiêc ³atwo dodawaæ nowe atrybuty
-czy nawet ca³e obiekty.
+%description -l pl.UTF-8
+Ten moduł zawiera kod do tworzenia obiektów Perla reprezentujących
+dowolne obiekty Nagiosa. Wszystkie klasy Perla są generowane
+automatycznie w czasie kompilacji, więc łatwo dodawać nowe atrybuty
+czy nawet całe obiekty.
%prep
%setup -q -n %{pdir}-%{pnam}-%{version}
rm -rf $RPM_BUILD_ROOT
./Build install
+install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+mv $RPM_BUILD_ROOT{%{_bindir}/*,%{_examplesdir}/%{name}-%{version}}
+
+rm -rf $RPM_BUILD_ROOT%{_mandir}/man1
+rm -f $RPM_BUILD_ROOT%{perl_vendorarch}/auto/.packlist
%clean
rm -rf $RPM_BUILD_ROOT
%doc ChangeLog README
%{perl_vendorlib}/Nagios
%{_mandir}/man3/*
+%{_examplesdir}/%{name}-%{version}