Update the change log
[profile/ivi/libpcap.git] / packaging / libpcap.spec
1 %define pcap_sover 0.9
2
3 Name: libpcap
4 Version: 1.1.1
5 Release: 3
6 Summary: A system-independent interface for user-level packet capture
7 Group: Development/Libraries
8 License: BSD with advertising
9 URL: http://www.tcpdump.org
10 BuildRequires: bison flex
11 BuildRequires: bluez-libs-devel
12
13 Source: http://www.tcpdump.org/release/%{name}-%{version}.tar.gz
14 Patch1: libpcap-man.patch
15 Patch2: libpcap-multilib.patch
16 Patch3: libpcap-s390.patch
17 Patch4: libpcap-nodev.patch
18
19 %description
20 Libpcap provides a portable framework for low-level network
21 monitoring.  Libpcap can provide network statistics collection,
22 security monitoring and network debugging.  Since almost every system
23 vendor provides a different interface for packet capture, the libpcap
24 authors created this system-independent API to ease in porting and to
25 alleviate the need for several system-dependent packet capture modules
26 in each application.
27
28 Install libpcap if you need to do low-level network traffic monitoring
29 on your network.
30
31 %package devel
32 Summary: Libraries and header files for the libpcap library
33 Group: Development/Libraries
34 Requires: %{name} = %{version}-%{release}
35
36 %description devel
37 Libpcap provides a portable framework for low-level network
38 monitoring.  Libpcap can provide network statistics collection,
39 security monitoring and network debugging.  Since almost every system
40 vendor provides a different interface for packet capture, the libpcap
41 authors created this system-independent API to ease in porting and to
42 alleviate the need for several system-dependent packet capture modules
43 in each application.
44
45 This package provides the libraries, include files, and other 
46 resources needed for developing libpcap applications.
47  
48 %prep
49 %setup -q
50
51 %patch1 -p1 -b .man 
52 %patch2 -p1 -b .multilib
53 %patch3 -p1 -b .s390
54 %patch4 -p1 -b .nodev
55
56 %build
57 export CFLAGS="$RPM_OPT_FLAGS $(getconf LFS_CFLAGS)"
58 %configure --enable-ipv6
59 make SOVERSION=%{pcap_sover}
60
61 %install
62 rm -rf $RPM_BUILD_ROOT
63
64 mkdir -p $RPM_BUILD_ROOT%{_bindir}
65 make SOVERSION=%{pcap_sover} DESTDIR=$RPM_BUILD_ROOT install
66 rm -f $RPM_BUILD_ROOT%{_libdir}/libpcap.a
67 rm -rf $RPM_BUILD_ROOT%{_datadir}/doc
68
69 %clean
70 rm -rf $RPM_BUILD_ROOT
71
72 %post -p /sbin/ldconfig
73
74 %postun -p /sbin/ldconfig
75
76 %files
77 %defattr(-,root,root)
78 %doc LICENSE README CHANGES CREDITS 
79 %{_libdir}/libpcap.so.*
80
81 %files devel
82 %defattr(-,root,root)
83 %dir %{_includedir}/pcap
84 %{_includedir}/pcap/*.h
85 %{_includedir}/*.h
86 %{_bindir}/pcap-config
87 %{_libdir}/libpcap.so
88 %{_mandir}/man?/*
89