Sophie

Sophie

distrib > Mandriva > 2006.0 > i586 > media > main-src > by-pkgid > 1607840df44450975b1f79506bb49aaa > files > 3

libpcap-0.9.1-1mdk.src.rpm

%define name libpcap
%define version 0.9.1
%define release 1mdk

%define	major 0
%define minor 9
%define libname %mklibname pcap %major
%define libdevel %libname-devel

Summary:        A system-independent interface for user-level packet capture
Name:		%{name}
Version:	%{version}
Release:	%{release}
License:	BSD
Group:		System/Libraries
URL:		http://www.tcpdump.org/
Source0:	http://www.tcpdump.org/release/%{name}-%{version}.tar.gz
Source1:	http://www.tcpdump.org/release/%{name}-%{version}.tar.gz.sig
BuildRequires:	bison
BuildRequires:	flex
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-buildroot

%description
Libpcap provides a portable framework for low-level network monitoring.
Libpcap can provide network statistics collection, security monitoring
and network debugging.  Since almost every system vendor provides a
different interface for packet capture, the libpcap authors created this
system-independent API to ease in porting and to alleviate the need for
several system-dependent packet capture modules in each application.

%package -n	%{libname}
Summary:	A system-independent interface for user-level packet capture
Group:          System/Libraries
Obsoletes:      %{name}
Provides:	%{name} = %{version}-%{release}

%description -n	%libname
Libpcap provides a portable framework for low-level network monitoring.
Libpcap can provide network statistics collection, security monitoring
and network debugging.  Since almost every system vendor provides a
different interface for packet capture, the libpcap authors created this
system-independent API to ease in porting and to alleviate the need for
several system-dependent packet capture modules in each application.


%package -n	%{libdevel}
Summary:	Static library and header files for the pcap library
Group:		Development/C
Obsoletes:	%{name}-devel
Provides:	%{name}-devel = %{version}-%{release}
Requires:	%{libname} = %{version}-%{release}

%description -n	%libdevel
Libpcap provides a portable framework for low-level network monitoring.
Libpcap can provide network statistics collection, security monitoring
and network debugging.  Since almost every system vendor provides a
different interface for packet capture, the libpcap authors created this
system-independent API to ease in porting and to alleviate the need for
several system-dependent packet capture modules in each application.

This package contains the static pcap library and its header files needed to
compile applications such as tcpdump, etc.

%prep
%setup -q

%build
%configure2_5x --enable-ipv6
%make "CCOPT=$RPM_OPT_FLAGS -fPIC"

# nah, doing it the hard way instead...
#%%make "CCOPT=$RPM_OPT_FLAGS -fPIC" shared

#
# (fg) FIXME - UGLY - HACK - but libpcap's Makefile doesn't allow to build a
# shared lib...
#

gcc -Wl,-soname,libpcap.so.%{major} -shared -fPIC -o libpcap.so.%{major}.%{minor} *.o

%install
[ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
%makeinstall_std

install -m755 libpcap.so.%{major}.%{minor} $RPM_BUILD_ROOT/%{_libdir}

pushd $RPM_BUILD_ROOT/%{_libdir} && {
	ln -s libpcap.so.%{major}.%{minor} libpcap.so.0
	ln -s libpcap.so.%{major}.%{minor} libpcap.so
} && popd

# install additional headers
install -m0644 pcap-int.h %{buildroot}%{_includedir}/

%clean
[ "%{buildroot}" != "/" ] && rm -rf %{buildroot}

%post -n %{libname} -p /sbin/ldconfig

%postun -n %{libname} -p /sbin/ldconfig

%files -n %{libname}
%defattr(-,root,root)
%doc README* CREDITS FILES INSTALL.txt LICENSE VERSION doc
%{_libdir}/libpcap.so.*

%files -n %{libdevel}
%defattr(-,root,root)
%doc CHANGES TODO
%{_includedir}/*
%{_libdir}/libpcap.so
%{_libdir}/libpcap.a
%{_mandir}/man3/pcap.3*

%changelog
* Wed Jul 13 2005 Oden Eriksson <oeriksson@mandriva.com> 0.9.1-1mdk
- 0.9.1
- bump minor to 9
- install additional headers

* Sun Dec 26 2004 Abel Cheung <deaddog@mandrake.org> 0.8.3-3mdk
- Adds signature
- Various spec fixes and cleanup

* Sat Apr 17 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 0.8.3-2mdk
- fix buildrequires
- drop redundant provides
- drop patch that wasn't applied

* Thu Apr 15 2004 Michael Scherer <mscherer@mandrakesoft.com> 0.8.3-1mdk
- New release 0.8.3
- remove patch #1
- force autoconf2.5

* Tue Jan 27 2004 Warly <warly@mandrakesoft.com> 0.8.1-1mdk
- new version

* Mon Sep  8 2003 Warly <warly@mandrakesoft.com> 0.7.2-3mdk
- mklibnamize

* Thu Jul 31 2003 Per Øyvind Karlsen <peroyvind@sintrax.net> 0.7.2-2mdk
- rebuild

* Fri Feb 28 2003 Vincent Danen <vdanen@mandrakesoft.com> 0.7.2-1mdk
- 0.7.2
- remove P0 (included upstream)

* Sun Feb 09 2003 Stefan van der Eijk <stefan@eijk.nu> 0.7.1-4mdk
- add patch for wireless sniffing (Airsnort & co)
- fix %%doc

* Thu Nov 14 2002 Warly <warly@mandrakesoft.com> 0.7.1-3mdk
- use gz for sources to be able to check md5

* Tue Sep  3 2002 Warly <warly@mandrakesoft.com> 0.7.1-2mdk
- remove obsolete P0 (Oden Eriksson)
- misc spec file fixes (Oden Eriksson)

* Sat Aug 10 2002 Warly <warly@mandrakesoft.com> 0.7.1-1mdk
- new version

* Mon Nov 19 2001 Philippe Libat <philippe@mandrakesoft.com> 0.6.2-3mdk
- fix libpcap link version 0.6 and requires

* Fri Oct 12 2001 Stefan van der Eijk <stefan@eijk.nu> 0.6.2-2mdk
- BuildRequires: byacc flex
- Copyright --> License

* Tue May  8 2001 Guillaume Cottenceau <gc@mandrakesoft.com> 0.6.2-1mdk
- version 0.6.2

* Mon Mar 12 2001 Jeff Garzik <jgarzik@mandrakesoft.com> 0.6.1-5mdk
- BuildRequires: autoconf

* Tue Feb 27 2001 Jeff Garzik <jgarzik@mandrakesoft.com> 0.6.1-4mdk
- Add more docs
- Build with fPIC for shared libraries.

* Sat Jan 13 2001 David BAUDENS <baudens@mandrakesoft.com> 0.6.1-3mdk
- Really fix libdification (thanks to Stefan van der Eijk)

* Fri Jan 12 2001 David BAUDENS <baudens@mandrakesoft.com> 0.6.1-2mdk
- Fix libdification
- Provides: libpcap
- Fix Requires section
- Fix name of SRPM

* Tue Jan 09 2001 Geoff <snailtalk@mandrakesoft.com> 0.6.1-1mdk
- new and shiny source.
- add a url for the source.

* Thu Jan 04 2001 Francis Galiegue <fg@mandrakesoft.com> 0.5.2-2mdk
- New lib policy:
  * s,libpcap,&0,
  * fixed requires
  * Obsoletes: libpcap and -devel
  * Serial not needed anymore

* Wed Nov  8 2000 Jeff Garzik <jgarzik@mandrakesoft.com> 0.5.2-1mdk
- Update to release version 0.5.2.

* Fri Jul 21 2000 Francis Galiegue <fg@mandrakesoft.com> 0.5-2mdk
- s,tmpdir,tmppath,
- removed unnecessary version and release in -devel

* Thu Jul 20 2000 Francis Galiegue <fg@mandrakesoft.com> 0.5-1mdk
- 0.5 stable
- Split from tcpdump source to is own source
- %files list cleanup
- Added dynamic lib - dirty hack
- split libpcap and -devel