]> git.pld-linux.org Git - packages/libpcap.git/blobdiff - libpcap.spec
- make sanitized pcap-int.h available to other packages (e.g. kismet)
[packages/libpcap.git] / libpcap.spec
index 1876d965bad45e25abbedecabc1fbffb154639c9..b97b26f6d2f91e199a84e9ced4e90c49b1c45efe 100644 (file)
@@ -5,17 +5,19 @@ Summary(pt_BR):       A libpcap fornece acesso ao modo prom
 Summary(ru):   ðÒÅÄÏÓÔÁ×ÌÑÅÔ ÄÏÓÔÕРˠÓÅÔÅ×ÙÍ ÉÎÔÅÒÆÅÊÓÁÍ × promiscuous-ÒÅÖÉÍÅ
 Summary(uk):   îÁÄÁ¤ ÄÏÓÔÕРÄÏ ÍÅÒÅÖÅ×ÉÈ ¦ÎÔÅÒÆÅÊӦננpromiscuous-ÒÅÖÉͦ
 Name:          libpcap
-Version:       0.7.2
-Release:       1
+Version:       0.8.1
+Release:       2
 Epoch:         2
-License:       GPL
+License:       BSD
 Group:         Libraries
 Source0:       http://www.tcpdump.org/release/%{name}-%{version}.tar.gz
-# Source0-md5: e3993a5409b98989c7a73e27c5df4d27
+# Source0-md5: f03f588e1f0ba783004d76f60507cebd
 Patch0:                %{name}-shared.patch
-BuildRequires: flex
+Patch1:                %{name}-ac25x.patch
+BuildRequires: autoconf >= 2.53
+BuildRequires: automake
 BuildRequires: bison
-BuildRequires: autoconf
+BuildRequires: flex
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 Obsoletes:     libpcap0
 
@@ -136,10 +138,16 @@ Biblioteka statyczna libpcap.
 óÔÁÔÉÞÎÁ Â¦Â̦ÏÔÅËÁ, ÎÅÏÂȦÄÎÁ ÄÌÑ ÐÒÏÇÒÁÍÕ×ÁÎÎÑ Ú libpcap.
 
 %prep
-%setup  -q -n %{name}-%{version}
+# -c because of "tar: Removing leading `libpcap-0.8.1/./' from member names"
+%setup -q -c
+# tar < 1.13.9x compat
+[ -f configure ] || cd %{name}-%{version}
 %patch0 -p1
+%patch1 -p1
 
 %build
+[ -f configure ] || cd %{name}-%{version}
+cp -f /usr/share/automake/config.sub .
 %{__autoconf}
 %configure \
        --with-pcap=linux \
@@ -148,28 +156,33 @@ Biblioteka statyczna libpcap.
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_includedir}/net \
-       $RPM_BUILD_ROOT{%{_libdir},%{_mandir}/man3}
+if [ ! -f configure ]; then
+       mv -f %{name}-%{version}/{CHANGES,CREDITS,LICENSE,README} .
+       cd %{name}-%{version}
+fi
 
 %{__make} install \
        DESTDIR=$RPM_BUILD_ROOT
 
-%post   -p /sbin/ldconfig
-%postun -p /sbin/ldconfig
+# some packages want it... but sanitize somehow
+# (don't depend on HAVE_{STRLCPY,SNPRINTF,VSNPRINTF} defines)
+sed -e '233,239d;242,251d' pcap-int.h > $RPM_BUILD_ROOT%{_includedir}/pcap-int.h
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post   -p /sbin/ldconfig
+%postun -p /sbin/ldconfig
+
 %files
 %defattr(644,root,root,755)
-%doc README CHANGES CREDITS
+%doc CHANGES CREDITS LICENSE README
 %attr(755,root,root) %{_libdir}/lib*.so.*.*
 
 %files devel
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/lib*.so
 %{_includedir}/*.h
-%{_includedir}/net/*.h
 %{_mandir}/man?/*
 
 %files static
This page took 0.107524 seconds and 4 git commands to generate.