%define sharktoolsver 0.1.5 Name: perl-Net-Sharktools Version: 0.009 Release: 0%{?dist} Summary: Use Wireshark's packet inspection capabilities in Perl Group: Development/Libraries License: GPLv2 URL: http://search.cpan.org/dist/Net-Sharktools/ Source0: http://search.cpan.org/CPAN/authors/id/N/NA/NANIS/Net-Sharktools-%{version}.tar.gz Source1: http://www.mit.edu/~armenb/sharktools/sharktools-%{sharktoolsver}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: perl(ExtUtils::MakeMaker) BuildRequires: perl(Test::More) BuildRequires: python-devel # wireshark - missing header files in the -devel subpackage # https://bugzilla.redhat.com/show_bug.cgi?id=671997 BuildRequires: wireshark-devel >= 1.4.3-2 # glib2-devel is pulled in by wireshark-devel Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) %description Net::Sharktools is an adaptation of the Python interface provided with the Sharktools package which is a "small set of tools that allow use of Wireshark's deep packet inspection capabilities in interpreted programming languages." %prep %setup -q -n Net-Sharktools-%{version} -a 1 %build # Build the sharktools static library cd sharktools-%{sharktoolsver} %configure \ --with-wireshark-src=%{_includedir}/wireshark \ --disable-matshark make cd .. # $ pkg-config --cflags glib-2.0 # -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include # $ pkg-config --libs glib-2.0 # -lglib-2.0 %{__perl} Makefile.PL INSTALLDIRS=vendor OPTIMIZE="$RPM_OPT_FLAGS" \ --wireshark-src %{_includedir}/wireshark/ \ --sharktools-src sharktools-%{sharktoolsver}/src \ --inc-path %{_includedir}/glib-2.0 \ --inc-path %{_libdir}/glib-2.0/include make %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT make pure_install PERL_INSTALL_ROOT=$RPM_BUILD_ROOT find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} \; find $RPM_BUILD_ROOT -type f -name '*.bs' -size 0 -exec rm -f {} \; find $RPM_BUILD_ROOT -depth -type d -exec rmdir {} 2>/dev/null \; %{_fixperms} $RPM_BUILD_ROOT/* %check make test %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc AUTHORS COPYING Changes README README.sharktools-0.1.5.txt %{perl_vendorarch}/auto/* %{perl_vendorarch}/Net* %{_mandir}/man3/* %changelog * Fri Feb 4 2011 Jose Pedro Oliveira - 0.009-1 - Updated to 0.009. * Tue Feb 1 2011 Jose Pedro Oliveira - 0.008-1 - Updated to 0.008. - License is now GPLv2. * Fri Jan 28 2011 Jose Pedro Oliveira - 0.005-1 - Updated to 0.005. * Thu Jan 27 2011 Jose Pedro Oliveira - 0.003-1 - Updated to 0.003. * Thu Jan 27 2011 Jose Pedro Oliveira - 0.002-2 - Disabled the parallel build of sharktools as it failed in mock. - Added the build requirement: perl(Test::More). * Tue Jan 25 2011 Jose Pedro Oliveira - 0.002-1 - Updated to 0.002. * Sun Jan 23 2011 Jose Pedro Oliveira - 0.001-1 - First build. # vim:set ai ts=4 sw=4 sts=4 et: