Name:           perl-IPTables-ChainMgr
Version:        0.9.9
Release:        1%{?_dist_release}
Summary:        Perl extension for manipulating iptables policies
License:        GPL+ or Artistic
Group:          Development/Libraries
URL:            http://www.cipherdyne.org/modules/
Source0:        http://www.cipherdyne.org/modules/IPTables-ChainMgr-%{version}.tar.bz2
Source1:        http://www.cipherdyne.org/modules/IPTables-ChainMgr-%{version}.tar.bz2.asc
BuildArch:      noarch
BuildRequires:  perl(ExtUtils::MakeMaker)
BuildRequires:  perl(IPTables::Parse), perl(NetAddr::IP)
Requires:       perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))

Vendor:         Project Vine
Distribution:   Vine Linux
Packager:       shaolin

%description
The IPTables::ChainMgr package provides an interface to manipulate iptables
policies on Linux systems through the direct execution of iptables
commands. Although making a perl extension of libiptc provided by the iptables
project is possible, it is easy to just execute iptables commands directly in
order to both parse and change the configuration of the policy. Further, this
simplifies installation since the only external requirement is (in the spirit
of scripting) to be able to point IPTables::ChainMgr at an installed iptables
binary instead of having to compile against a library.

%prep
%setup -q -n IPTables-ChainMgr-%{version}

%build
%{__perl} Makefile.PL INSTALLDIRS=vendor
make %{?_smp_mflags}

%install
rm -rf %{buildroot}
make pure_install PERL_INSTALL_ROOT=%{buildroot}

find %{buildroot} -type f -name .packlist -exec rm -f {} \;
find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null \;

%{_fixperms} %{buildroot}/*

%check
make test

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root,-)
%doc Changes README
%{perl_vendorlib}/*
%{_mandir}/man3/*

%changelog
* Thu Mar 01 2012 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 0.9.9-1
- initial build for Vine Linux

* Mon Feb 27 2012 Miloslav Trmač <mitr@redhat.com> - 0.9.9-1
- Update to IPTables-ChainMgr-0.9.9

* Tue Jan 10 2012 Miloslav Trmač <mitr@redhat.com> - 0.9-9
- Avoid deprecated use of qw()
  Resolves: #771781

* Tue Jun 21 2011 Marcela Mašláňová <mmaslano@redhat.com> - 0.9-8
- Perl mass rebuild

* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Mon Dec 20 2010 Marcela Maslanova <mmaslano@redhat.com> - 0.9-6
- 661697 rebuild for fixing problems with vendorach/lib

* Sun May 02 2010 Marcela Maslanova <mmaslano@redhat.com>
- Mass rebuild with perl-5.12.0

- Drop no longer required references to BuildRoot

* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Fri Feb 13 2009 Miloslav Trmač <mitr@redhat.com> - 0.9-1
- Update to IPTables-ChainMgr-0.9.

* Tue Oct 21 2008 Miloslav Trmač <mitr@redhat.com> - 0.8-1
- Update to IPTables-ChainMgr-0.8.

* Wed Jul 30 2008 Miloslav Trmač <mitr@redhat.com> 0.7-1
- Initial package.
