Author: rpaulo
Date: Fri Oct 29 18:43:23 2010
New Revision: 214518
URL: http://svn.freebsd.org/changeset/base/214518

Log:
  Merge libpcap-1.1.1.

Added:
  head/contrib/libpcap/ChmodBPF/
     - copied from r214514, vendor/libpcap/dist/ChmodBPF/
  head/contrib/libpcap/README.Win32
     - copied unchanged from r214514, vendor/libpcap/dist/README.Win32
  head/contrib/libpcap/README.aix
     - copied unchanged from r214514, vendor/libpcap/dist/README.aix
  head/contrib/libpcap/README.dag
     - copied unchanged from r214514, vendor/libpcap/dist/README.dag
  head/contrib/libpcap/README.hpux
     - copied unchanged from r214514, vendor/libpcap/dist/README.hpux
  head/contrib/libpcap/README.linux
     - copied unchanged from r214514, vendor/libpcap/dist/README.linux
  head/contrib/libpcap/README.macosx
     - copied unchanged from r214514, vendor/libpcap/dist/README.macosx
  head/contrib/libpcap/README.septel
     - copied unchanged from r214514, vendor/libpcap/dist/README.septel
  head/contrib/libpcap/README.sita
     - copied unchanged from r214514, vendor/libpcap/dist/README.sita
  head/contrib/libpcap/README.tru64
     - copied unchanged from r214514, vendor/libpcap/dist/README.tru64
  head/contrib/libpcap/SUNOS4/
     - copied from r214514, vendor/libpcap/dist/SUNOS4/
  head/contrib/libpcap/Win32/
     - copied from r214514, vendor/libpcap/dist/Win32/
  head/contrib/libpcap/msdos/
     - copied from r214514, vendor/libpcap/dist/msdos/
  head/contrib/libpcap/opentest.c
     - copied unchanged from r214514, vendor/libpcap/dist/opentest.c
  head/contrib/libpcap/org.tcpdump.chmod_bpf.plist
     - copied unchanged from r214514, 
vendor/libpcap/dist/org.tcpdump.chmod_bpf.plist
  head/contrib/libpcap/pcap-can-linux.c
     - copied unchanged from r214514, vendor/libpcap/dist/pcap-can-linux.c
  head/contrib/libpcap/pcap-can-linux.h
     - copied unchanged from r214514, vendor/libpcap/dist/pcap-can-linux.h
  head/contrib/libpcap/pcap-common.c
     - copied unchanged from r214514, vendor/libpcap/dist/pcap-common.c
  head/contrib/libpcap/pcap-common.h
     - copied unchanged from r214514, vendor/libpcap/dist/pcap-common.h
  head/contrib/libpcap/pcap-snf.c
     - copied unchanged from r214514, vendor/libpcap/dist/pcap-snf.c
  head/contrib/libpcap/pcap-snf.h
     - copied unchanged from r214514, vendor/libpcap/dist/pcap-snf.h
  head/contrib/libpcap/pcap/ipnet.h
     - copied unchanged from r214514, vendor/libpcap/dist/pcap/ipnet.h
  head/contrib/libpcap/selpolltest.c
     - copied unchanged from r214514, vendor/libpcap/dist/selpolltest.c
  head/contrib/libpcap/sf-pcap-ng.c
     - copied unchanged from r214514, vendor/libpcap/dist/sf-pcap-ng.c
  head/contrib/libpcap/sf-pcap-ng.h
     - copied unchanged from r214514, vendor/libpcap/dist/sf-pcap-ng.h
  head/contrib/libpcap/sf-pcap.c
     - copied unchanged from r214514, vendor/libpcap/dist/sf-pcap.c
  head/contrib/libpcap/sf-pcap.h
     - copied unchanged from r214514, vendor/libpcap/dist/sf-pcap.h
Deleted:
  head/contrib/libpcap/net/bpf_filter.c
Modified:
  head/contrib/libpcap/CHANGES
  head/contrib/libpcap/CREDITS
  head/contrib/libpcap/INSTALL.txt
  head/contrib/libpcap/Makefile.in
  head/contrib/libpcap/README
  head/contrib/libpcap/TODO
  head/contrib/libpcap/VERSION
  head/contrib/libpcap/arcnet.h
  head/contrib/libpcap/atmuni31.h
  head/contrib/libpcap/bpf/net/bpf_filter.c
  head/contrib/libpcap/bpf_dump.c
  head/contrib/libpcap/bpf_image.c
  head/contrib/libpcap/config.guess
  head/contrib/libpcap/config.h.in
  head/contrib/libpcap/config.sub
  head/contrib/libpcap/configure
  head/contrib/libpcap/configure.in
  head/contrib/libpcap/dlpisubs.c
  head/contrib/libpcap/dlpisubs.h
  head/contrib/libpcap/etherent.c
  head/contrib/libpcap/ethertype.h
  head/contrib/libpcap/fad-getad.c
  head/contrib/libpcap/fad-gifc.c
  head/contrib/libpcap/fad-glifc.c
  head/contrib/libpcap/fad-null.c
  head/contrib/libpcap/fad-win32.c
  head/contrib/libpcap/filtertest.c
  head/contrib/libpcap/gencode.c
  head/contrib/libpcap/gencode.h
  head/contrib/libpcap/grammar.y
  head/contrib/libpcap/inet.c
  head/contrib/libpcap/lbl/os-aix4.h
  head/contrib/libpcap/lbl/os-hpux11.h
  head/contrib/libpcap/lbl/os-osf4.h
  head/contrib/libpcap/lbl/os-osf5.h
  head/contrib/libpcap/lbl/os-solaris2.h
  head/contrib/libpcap/lbl/os-sunos4.h
  head/contrib/libpcap/lbl/os-ultrix4.h
  head/contrib/libpcap/llc.h
  head/contrib/libpcap/missing/snprintf.c
  head/contrib/libpcap/nametoaddr.c
  head/contrib/libpcap/nlpid.h
  head/contrib/libpcap/optimize.c
  head/contrib/libpcap/pcap-bpf.c
  head/contrib/libpcap/pcap-bpf.h
  head/contrib/libpcap/pcap-bt-linux.c
  head/contrib/libpcap/pcap-bt-linux.h
  head/contrib/libpcap/pcap-config.1
  head/contrib/libpcap/pcap-config.in
  head/contrib/libpcap/pcap-dag.c
  head/contrib/libpcap/pcap-dag.h
  head/contrib/libpcap/pcap-dlpi.c
  head/contrib/libpcap/pcap-dos.c
  head/contrib/libpcap/pcap-dos.h
  head/contrib/libpcap/pcap-enet.c
  head/contrib/libpcap/pcap-filter.manmisc.in
  head/contrib/libpcap/pcap-int.h
  head/contrib/libpcap/pcap-libdlpi.c
  head/contrib/libpcap/pcap-linktype.manmisc.in
  head/contrib/libpcap/pcap-linux.c
  head/contrib/libpcap/pcap-namedb.h
  head/contrib/libpcap/pcap-nit.c
  head/contrib/libpcap/pcap-null.c
  head/contrib/libpcap/pcap-pf.c
  head/contrib/libpcap/pcap-savefile.manfile.in
  head/contrib/libpcap/pcap-septel.c
  head/contrib/libpcap/pcap-septel.h
  head/contrib/libpcap/pcap-sita.html
  head/contrib/libpcap/pcap-snit.c
  head/contrib/libpcap/pcap-snoop.c
  head/contrib/libpcap/pcap-stdinc.h
  head/contrib/libpcap/pcap-usb-linux.c
  head/contrib/libpcap/pcap-usb-linux.h
  head/contrib/libpcap/pcap-win32.c
  head/contrib/libpcap/pcap.3pcap.in
  head/contrib/libpcap/pcap.c
  head/contrib/libpcap/pcap.h
  head/contrib/libpcap/pcap/bluetooth.h
  head/contrib/libpcap/pcap/bpf.h
  head/contrib/libpcap/pcap/namedb.h
  head/contrib/libpcap/pcap/pcap.h
  head/contrib/libpcap/pcap/sll.h
  head/contrib/libpcap/pcap/usb.h
  head/contrib/libpcap/pcap/vlan.h
  head/contrib/libpcap/pcap_activate.3pcap
  head/contrib/libpcap/pcap_breakloop.3pcap
  head/contrib/libpcap/pcap_can_set_rfmon.3pcap
  head/contrib/libpcap/pcap_close.3pcap
  head/contrib/libpcap/pcap_compile.3pcap.in
  head/contrib/libpcap/pcap_create.3pcap
  head/contrib/libpcap/pcap_datalink.3pcap.in
  head/contrib/libpcap/pcap_datalink_name_to_val.3pcap
  head/contrib/libpcap/pcap_datalink_val_to_name.3pcap
  head/contrib/libpcap/pcap_dump.3pcap
  head/contrib/libpcap/pcap_dump_close.3pcap
  head/contrib/libpcap/pcap_dump_file.3pcap
  head/contrib/libpcap/pcap_dump_flush.3pcap
  head/contrib/libpcap/pcap_dump_ftell.3pcap
  head/contrib/libpcap/pcap_dump_open.3pcap.in
  head/contrib/libpcap/pcap_file.3pcap
  head/contrib/libpcap/pcap_fileno.3pcap
  head/contrib/libpcap/pcap_findalldevs.3pcap
  head/contrib/libpcap/pcap_free_datalinks.3pcap
  head/contrib/libpcap/pcap_freealldevs.3pcap
  head/contrib/libpcap/pcap_freecode.3pcap
  head/contrib/libpcap/pcap_get_selectable_fd.3pcap
  head/contrib/libpcap/pcap_geterr.3pcap
  head/contrib/libpcap/pcap_inject.3pcap
  head/contrib/libpcap/pcap_is_swapped.3pcap
  head/contrib/libpcap/pcap_lib_version.3pcap
  head/contrib/libpcap/pcap_list_datalinks.3pcap.in
  head/contrib/libpcap/pcap_lookupdev.3pcap
  head/contrib/libpcap/pcap_lookupnet.3pcap
  head/contrib/libpcap/pcap_loop.3pcap
  head/contrib/libpcap/pcap_major_version.3pcap
  head/contrib/libpcap/pcap_next_ex.3pcap
  head/contrib/libpcap/pcap_offline_filter.3pcap
  head/contrib/libpcap/pcap_open_dead.3pcap.in
  head/contrib/libpcap/pcap_open_live.3pcap
  head/contrib/libpcap/pcap_open_offline.3pcap.in
  head/contrib/libpcap/pcap_set_buffer_size.3pcap
  head/contrib/libpcap/pcap_set_datalink.3pcap
  head/contrib/libpcap/pcap_set_promisc.3pcap
  head/contrib/libpcap/pcap_set_rfmon.3pcap
  head/contrib/libpcap/pcap_set_snaplen.3pcap
  head/contrib/libpcap/pcap_set_timeout.3pcap
  head/contrib/libpcap/pcap_setdirection.3pcap
  head/contrib/libpcap/pcap_setfilter.3pcap
  head/contrib/libpcap/pcap_setnonblock.3pcap
  head/contrib/libpcap/pcap_snapshot.3pcap
  head/contrib/libpcap/pcap_stats.3pcap
  head/contrib/libpcap/pcap_statustostr.3pcap
  head/contrib/libpcap/pcap_strerror.3pcap
  head/contrib/libpcap/ppp.h
  head/contrib/libpcap/runlex.sh
  head/contrib/libpcap/savefile.c
  head/contrib/libpcap/scanner.l
  head/contrib/libpcap/sunatmpos.h
Directory Properties:
  head/contrib/libpcap/   (props changed)

Modified: head/contrib/libpcap/CHANGES
==============================================================================
--- head/contrib/libpcap/CHANGES        Fri Oct 29 18:41:09 2010        
(r214517)
+++ head/contrib/libpcap/CHANGES        Fri Oct 29 18:43:23 2010        
(r214518)
@@ -1,4 +1,77 @@
-@(#) $Header: /tcpdump/master/libpcap/CHANGES,v 1.67.2.4 2008-10-28 00:27:42 
ken Exp $ (LBL)
+Thu.    April 1, 2010.  [email protected].
+Summary for 1.1.1 libpcap release
+       Update CHANGES to reflect more of the changes in 1.1.0.
+       Fix build on RHEL5.
+       Fix shared library build on AIX.
+
+Thu.   March 11, 2010.  [email protected]/[email protected].
+Summary for 1.1.0 libpcap release
+       Add SocketCAN capture support
+       Add Myricom SNF API support
+       Update Endace DAG and ERF support
+       Add support for shared libraries on Solaris, HP-UX, and AIX
+       Build, install, and un-install shared libraries by default;
+         don't build/install shared libraries on platforms we don't support
+       Fix building from a directory other than the source directory
+       Fix compiler warnings and builds on some platforms
+       Update config.guess and config.sub
+       Support monitor mode on mac80211 devices on Linux
+       Fix USB memory-mapped capturing on Linux; it requires a new DLT_
+         value
+       On Linux, scan /sys/class/net for devices if we have it; scan
+         it, or /proc/net/dev if we don't have /sys/class/net, even if
+         we have getifaddrs(), as it'll find interfaces with no
+         addresses
+       Add limited support for reading pcap-ng files
+       Fix BPF driver-loading error handling on AIX
+       Support getting the full-length interface description on FreeBSD
+       In the lexical analyzer, free up any addrinfo structure we got back
+         from getaddrinfo().
+       Add support for BPF and libdlpi in OpenSolaris (and SXCE)
+       Hyphenate "link-layer" everywhere
+       Add /sys/kernel/debug/usb/usbmon to the list of usbmon locations
+       In pcap_read_linux_mmap(), if there are no frames available, call
+         poll() even if we're in non-blocking mode, so we pick up
+         errors, and check for the errors in question.
+       Note that poll() works on BPF devices is Snow Leopard
+       If an ENXIO or ENETDOWN is received, it may mean the device has
+         gone away.  Deal with it.
+       For BPF, raise the default capture buffer size to from 32k to 512k
+       Support ps_ifdrop on Linux
+       Added a bunch of #ifdef directives to make wpcap.dll (WinPcap) compile
+        under cygwin.
+       Changes to Linux mmapped captures.
+       Fix bug where create_ring would fail for particular snaplen and
+         buffer size combinations
+       Update pcap-config so that it handles libpcap requiring
+         additional libraries
+       Add workaround for threadsafeness on Windows
+       Add missing mapping for DLT_ENC <-> LINKTYPE_ENC
+       DLT: Add DLT_CAN_SOCKETCAN
+       DLT: Add Solaris ipnet
+       Don't check for DLT_IPNET if it's not defined
+       Add link-layer types for Fibre Channel FC-2
+       Add link-layer types for Wireless HART
+       Add link-layer types for AOS
+       Add link-layer types for DECT
+       Autoconf fixes (AIX, HP-UX, OSF/1, Tru64 cleanups)
+       Install headers unconditionally, and include vlan.h/bluetooth.h if
+         enabled
+       Autoconf fixes+cleanup
+       Support enabling/disabling bluetooth (--{en,dis}able-bluetooth)
+       Support disabling SITA support (--without-sita)
+       Return -1 on failure to create packet ring (if supported but
+         creation failed)
+       Fix handling of 'any' device, so that it can be opened, and no longer
+         attempt to open it in Monitor mode
+       Add support for snapshot length for USB Memory-Mapped Interface
+       Fix configure and build on recent Linux kernels
+       Fix memory-mapped Linux capture to support pcap_next() and
+         pcap_next_ex()
+       Fixes for Linux USB capture
+       DLT: Add DLT_LINUX_EVDEV
+       DLT: Add DLT_GSMTAP_UM
+       DLT: Add DLT_GSMTAP_ABIS
 
 Mon.    October 27, 2008.  [email protected].  Summary for 1.0.0 libpcap 
release
        Compile with IPv6 support by default
@@ -12,7 +85,10 @@ Mon.    October 27, 2008.  k...@netfuncti
        Variable length 802.11 header support
        X2E data type support 
        SITA ACN Interface support - see README.sita
+       Support for memory-mapped capture on Linux
        Support for zerocopy BPF on platforms that support it
+       Support for setting buffer size when opening devices
+       Support for setting monitor mode when opening 802.11 devices
        Better support for dealing with VLAN tagging/stripping on Linux
        Fix dynamic library support on OSX
        Return PCAP_ERROR_IFACE_NOT_UP if the interface isn't 'UP', so 
applications
@@ -22,7 +98,7 @@ Mon.    October 27, 2008.  k...@netfuncti
        On Linux, ignore ENETDOWN so we can continue to capture packets if the 
         interface goes down and comes back up again.
        On Linux, support new tpacket frame headers (2.6.27+)
-       On Mac OS X, add scripts for changing permissions on /dev/pbf* and 
launchd plist
+       On Mac OS X, add scripts for changing permissions on /dev/bpf* and 
launchd plist
        On Solaris, support 'passive mode' on systems that support it
        Fixes to autoconf and general build environment
        Man page reorganization + cleanup

Modified: head/contrib/libpcap/CREDITS
==============================================================================
--- head/contrib/libpcap/CREDITS        Fri Oct 29 18:41:09 2010        
(r214517)
+++ head/contrib/libpcap/CREDITS        Fri Oct 29 18:43:23 2010        
(r214518)
@@ -10,9 +10,10 @@ The current maintainers:
 Additional people who have contributed patches:
 
        Alan Bawden                     <Alan at LCS dot MIT dot EDU>
+       Albert Chin                     <china at thewrittenword dot com>
        Alexander 'Leo' Bergolth        <Leo dot Bergolth at wu-wien dot ac dot 
at>
        Alexey Kuznetsov                <kuznet at ms2 dot inr dot ac dot ru>
-       Albert Chin                     <china at thewrittenword dot com>
+       Alon Bar-Lev                    <alonbl at sourceforge dot net>
        Andrew Brown                    <atatat at atatdot dot net>
        Antti Kantee                    <pooka at netbsd dot org>
        Arien Vijn                      <arienvijn at sourceforge dot net>
@@ -23,24 +24,28 @@ Additional people who have contributed p
        Charles M. Hannum               <mycroft at netbsd dot org>
        Chris G. Demetriou              <cgd at netbsd dot org>
        Chris Lightfoot                 <cwrl at users dot sourceforge dot net>
+       Chris Maynard                   <Chris dot Maynard at gtech dot com>
        Chris Pepper                    <pepper at mail dot reppep dot com>
+       Christian Bell                  <csbell at myri dot com>
        Christian Peron                 <csjp at freebsd dot org>
        Daniele Orlandi                 <daniele at orlandi dot com>
-       Darren Reed                     <darrenr at reed dot wattle dot id dot 
au>
+       Darren Reed                     <darrenr at sun dot com>
        David Kaelbling                 <drk at sgi dot com>
        David Young                     <dyoung at ojctech dot com>
        Dean Gaudet                     <dean at arctic dot org>
        Don Ebright                     <Don dot Ebright at compuware dot com> 
        Dug Song                        <dugsong at monkey dot org>
+       Dustin Spicuzza                 <dustin at virtualroadside dot com>
        Eric Anderson                   <anderse at hpl dot hp dot com>
        Erik de Castro Lopo             <erik dot de dot castro dot lopo at 
sensorynetworks dot com>
+       Felix Obenhuber                 <felix at obenhuber dot de>
        Florent Drouin                  <Florent dot Drouin at alcatel-lucent 
dot fr>
        Franz Schaefer                  <schaefer at mond dot at>
        Fulko Hew                       <fulko dot hew at gmail dot com>
+       Fumiyuki Shimizu                <fumifumi at abacustech dot jp>
        Gianluca Varenni                <varenni at netgroup-serv dot polito 
dot it>
        Gilbert Hoyek                   <gil_hoyek at hotmail dot com>
        Gisle Vanem                     <gvanem at broadpark dot no>
-       Gisle Vanem                     <giva at bgnett dot no>
        Graeme Hewson                   <ghewson at cix dot compulink dot co 
dot uk>
        Greg Stark                      <gsstark at mit dot edu>
        Greg Troxel                     <gdt at ir dot bbn dot com>
@@ -53,11 +58,13 @@ Additional people who have contributed p
        Jason R. Thorpe                 <thorpej at netbsd dot org>
        Javier Achirica                 <achirica at ttd dot net>
        Jean Tourrilhes                 <jt at hpl dot hp dot com>
+       Jean-Louis Charton              <Jean-Louis.CHARTON at oikialog dot com>
        Jefferson Ogata                 <jogata at nodc dot noaa dot gov>
        Jesper Peterson                 <jesper at endace dot com>
        Joerg Mayer                     <jmayer at loplof dot de>
        John Bankier                    <jbankier at rainfinity dot com>
        Jon Lindgren                    <jonl at yubyub dot net>
+       Jon Smirl                       <jonsmirl at gmail dot com>
        Juergen Schoenwaelder           <schoenw at ibr dot cs dot tu-bs dot de>
        Jung-uk Kim                     <jkim at FreeBSD dot org>
        Kazushi Sugyo                   <sugyo at pb dot jp dot nec dot com>
@@ -67,19 +74,22 @@ Additional people who have contributed p
        Krzysztof Halasa                <khc at pm dot waw dot pl>
        Lorenzo Cavallaro               <sullivan at sikurezza dot org>
        Loris Degioanni                 <loris at netgroup-serv dot polito dot 
it>
-       Love H�rnquist-�strand          <lha at stacken dot kth dot se>
+       Love Hörnquist-Åstrand          <lha at stacken dot kth dot se>
        Luis Martin Garcia              <luis dot mgarc at gmail dot com>
        Maciej W. Rozycki               <macro at ds2 dot pg dot gda dot pl>
        Marcus Felipe Pereira           <marcus at task dot com dot br>
        Mark C. Brown                   <mbrown at hp dot com>
        Mark Pizzolato                  <List-tcpdump-workers at subscriptions 
dot pizzolato dot net>
+       Markus Mayer                    <markus_mayer at sourceforge dot net>
        Martin Husemann                 <martin at netbsd dot org>
+       Márton Németh                   <nm127 at freemail dot hu>
        Matthew Luckie                  <mjl at luckie dot org dot nz>
        Max Laier                       <max at love2party dot net>
        Mike Frysinger                  <vapier at gmail dot com>
        Mike Kershaw                    <dragorn at kismetwireless dot net>
        Mike Wiacek                     <mike at iroot dot net>
        Monroe Williams                 <monroe at pobox dot com>
+       N. Leiten                       <nleiten at sourceforge dot net>
        Nicolas Dade                    <ndade at nsd dot dyndns dot org>
        Octavian Cerna                  <tavy at ylabs dot com>
        Olaf Kirch                      <okir at caldera dot de>
@@ -93,15 +103,20 @@ Additional people who have contributed p
        Pawel Pokrywka                  <publicpp at gmail dot com>
        Peter Fales                     <peter at fales-lorenz dot net>
        Peter Jeremy                    <peter dot jeremy at alcatel dot com 
dot au>
+       Peter Volkov                    <pva at gentoo dot org>
        Phil Wood                       <cpw at lanl dot gov>
        Rafal Maszkowski                <rzm at icm dot edu dot pl>
                                        <rcb-isis at users dot sourceforge dot 
net>
        Richard Stearn                  <richard at rns-stearn dot demon dot co 
dot uk>
        Rick Jones                      <raj at cup dot hp dot com>
+       Robert Edmonds                  <stu-42 at sourceforge dot net>
+       Roberto Mariani                 <jelot-tcpdump at jelot dot it>
+       Romain Francoise                <rfrancoise at debian dot org>
        Sagun Shakya                    <sagun dot shakya at sun dot com>
        Scott Barron                    <sb125499 at ohiou dot edu>
        Scott Gifford                   <sgifford at tir dot com>
        Sebastian Krahmer               <krahmer at cs dot uni-potsdam dot de>
+       Sebastien Roy                   <Sebastien dot Roy at Sun dot COM>
        Sepherosa Ziehau                <sepherosa at gmail dot com>
        Shaun Clowes                    <delius at progsoc dot uts dot edu dot 
au>
        Solomon Peachy                  <pizza at shaftnet dot org>
@@ -109,12 +124,16 @@ Additional people who have contributed p
        Stephen Donnelly                <stephen at endace dot com>
        Takashi Yamamoto                <yamt at mwd dot biglobe dot ne dot jp>
        Tanaka Shin-ya                  <zstanaka at archer dot livedoor dot 
com>
+       Tobias Poschwatta               <posch at sourceforge dot net>
        Tony Li                         <tli at procket dot com>
        Torsten Landschoff              <torsten at debian dot org>
        Uns Lider                       <unslider at miranda dot org>
        Uwe Girlich                     <Uwe dot Girlich at philosys dot de>
+       Wesley Shields                  <wxs at FreeBSD dot org>
        Xianjie Zhang                   <xzhang at cup dot hp dot com>
+       Xin Li                          <delphij at FreeBSD dot org>
        Yen Yen Lim
+       Yvan Vanhullebus                <vanhu at sourceforge dot net>
        Yoann Vandoorselaere            <yoann at prelude-ids dot org>
 
 The original LBL crew:

Modified: head/contrib/libpcap/INSTALL.txt
==============================================================================
--- head/contrib/libpcap/INSTALL.txt    Fri Oct 29 18:41:09 2010        
(r214517)
+++ head/contrib/libpcap/INSTALL.txt    Fri Oct 29 18:43:23 2010        
(r214518)
@@ -1,4 +1,4 @@
-@(#) $Header: /tcpdump/master/libpcap/INSTALL.txt,v 1.21.2.8 2008-06-12 
20:25:38 guy Exp $ (LBL)
+@(#) $Header: /tcpdump/master/libpcap/INSTALL.txt,v 1.29 2008-06-12 20:21:51 
guy Exp $ (LBL)
 
 To build libpcap, run "./configure" (a shell script). The configure
 script will determine your system attributes and generate an

Modified: head/contrib/libpcap/Makefile.in
==============================================================================
--- head/contrib/libpcap/Makefile.in    Fri Oct 29 18:41:09 2010        
(r214517)
+++ head/contrib/libpcap/Makefile.in    Fri Oct 29 18:43:23 2010        
(r214518)
@@ -17,7 +17,7 @@
 #  WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
 #  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 #
-# @(#) $Header: /tcpdump/master/libpcap/Makefile.in,v 1.108.2.28 2008-10-23 
22:13:21 guy Exp $ (LBL)
+# @(#) $Header: /tcpdump/master/libpcap/Makefile.in,v 1.142 2008-11-22 
17:30:24 guy Exp $ (LBL)
 
 #
 # Various configurable paths (remember to edit Makefile.in, not Makefile)
@@ -44,14 +44,17 @@ VPATH = @srcdir@
 # You shouldn't need to edit anything below.
 #
 
+LD = /usr/bin/ld
 CC = @CC@
 CCOPT = @V_CCOPT@
 INCLS = -I. @V_INCLS@
 DEFS = @DEFS@ @V_DEFS@
-LIBS = @V_LIBS@
-DAGLIBS = @DAGLIBS@
-DEPLIBS = @DEPLIBS@
+ADDLOBJS = @ADDLOBJS@
+ADDLARCHIVEOBJS = @ADDLARCHIVEOBJS@
+LIBS = @LIBS@
+LDFLAGS = @LDFLAGS@
 DYEXT = @DYEXT@
+V_RPATH_OPT = @V_RPATH_OPT@
 PROG=libpcap
 
 # Standard CFLAGS
@@ -77,12 +80,13 @@ YACC = @V_YACC@
        @rm -f $@
        $(CC) $(CFLAGS) -c $(srcdir)/$*.c
 
-PSRC = pc...@[email protected] @USB_SRC@ @BT_SRC@
+PSRC = pc...@[email protected] @USB_SRC@ @BT_SRC@ @CAN_SRC@
 FSRC =  f...@[email protected]
 SSRC =  @SSRC@
-CSRC = pcap.c inet.c gencode.c optimize.c nametoaddr.c \
-       etherent.c savefile.c bpf_filter.c bpf_image.c bpf_dump.c
-GENSRC = scanner.c grammar.c version.c
+CSRC = pcap.c inet.c gencode.c optimize.c nametoaddr.c etherent.c \
+       savefile.c sf-pcap.c sf-pcap-ng.c pcap-common.c \
+       bpf_image.c bpf_dump.c
+GENSRC = scanner.c grammar.c bpf_filter.c version.c
 LIBOBJS = @LIBOBJS@
 
 SRC =  $(PSRC) $(FSRC) $(CSRC) $(SSRC) $(GENSRC)
@@ -90,8 +94,20 @@ SRC =        $(PSRC) $(FSRC) $(CSRC) $(SSRC) $(
 # We would like to say "OBJ = $(SRC:.c=.o)" but Ultrix's make cannot
 # hack the extra indirection
 OBJ =  $(PSRC:.c=.o) $(FSRC:.c=.o) $(CSRC:.c=.o) $(SSRC:.c=.o) $(GENSRC:.c=.o) 
$(LIBOBJS)
-HDR = \
-       acconfig.h \
+PUBHDR = \
+       pcap.h \
+       pcap-bpf.h \
+       pcap-namedb.h \
+       pcap/bpf.h \
+       pcap/bluetooth.h \
+       pcap/ipnet.h \
+       pcap/namedb.h \
+       pcap/pcap.h \
+       pcap/sll.h \
+       pcap/vlan.h \
+       pcap/usb.h
+
+HDR = $(PUBHDR) \
        arcnet.h \
        atmuni31.h \
        ethertype.h \
@@ -99,30 +115,23 @@ HDR = \
        ieee80211.h \
        llc.h \
        nlpid.h \
-       pcap/bluetooth.h \
-       pcap/bpf.h \
-       pcap/namedb.h \
-       pcap/pcap.h \
-       pcap/sll.h \
-       pcap/usb.h \
-       pcap/vlan.h \
-       pcap.h \
+       pcap-common.h \
        pcap-int.h \
-       pcap-namedb.h \
        pcap-stdinc.h \
        ppp.h \
+       sf-pcap.h \
+       sf-pcap-ng.h \
        sunatmpos.h
 
 GENHDR = \
        scanner.h tokdefs.h version.h
 
-TAGHDR = \
-       pcap-bpf.h
-
 TAGFILES = \
-       $(SRC) $(HDR) $(TAGHDR)
+       $(SRC) $(HDR)
 
-CLEANFILES = $(OBJ) libpcap.a $(GENSRC) $(GENHDR) lex.yy.c
+CLEANFILES = $(OBJ) libpcap.* filtertest findalldevstest selpolltest \
+       opentest $(PROG)-`cat $(srcdir)/VERSION`.tar.gz $(GENSRC) $(GENHDR) \
+       lex.yy.c pcap-config
 
 MAN1 = pcap-config.1
 
@@ -254,13 +263,14 @@ EXTRA_DIST = \
        msdos/pktdrvr.c \
        msdos/pktdrvr.h \
        msdos/readme.dos \
-       net/bpf_filter.c \
+       opentest.c \
        org.tcpdump.chmod_bpf.plist \
        packaging/pcap.spec.in \
        pcap-bpf.c \
-       pcap-bpf.h \
        pcap-bt-linux.c \
        pcap-bt-linux.h \
+       pcap-can-linux.c \
+       pcap-can-linux.h \
        pcap-config.in \
        pcap-dag.c \
        pcap-dag.h \
@@ -280,6 +290,8 @@ EXTRA_DIST = \
        pcap-sita.h \
        pcap-sita.c \
        pcap-sita.html \
+       pcap-snf.c \
+       pcap-snf.h \
        pcap-snit.c \
        pcap-snoop.c \
        pcap-usb-linux.c \
@@ -287,6 +299,7 @@ EXTRA_DIST = \
        pcap-win32.c \
        runlex.sh \
        scanner.l \
+       selpolltest.c \
        Win32/Include/Gnuc.h \
        Win32/Include/addrinfo.h \
        Win32/Include/bittypes.h \
@@ -311,42 +324,94 @@ EXTRA_DIST = \
        Win32/Src/inet_net.c \
        Win32/Src/inet_pton.c
 
-all: libpcap.a pcap-config
+all: libpcap.a shared pcap-config
 
 libpcap.a: $(OBJ)
        @rm -f $@
-       $(AR) rc $@ $(OBJ) $(LIBS)
+       ar rc $@ $(OBJ) $(ADDLARCHIVEOBJS)
        $(RANLIB) $@
 
 shared: libpcap.$(DYEXT)
 
-#
-# XXX - this works with GNU ld, but won't necessarily work with native
-# ld on, for example, various SVR4-flavored platforms, or Digital UNIX.
-#
 libpcap.so: $(OBJ)
        @rm -f $@
-       $(CC) -shared -Wl,-soname,[email protected] -o $...@.`cat $(srcdir)/VERSION` 
$(OBJ) $(DAGLIBS)
+       VER=`cat $(srcdir)/VERSION`; \
+       MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \
+       @V_SHLIB_CMD@ @V_SHLIB_OPT@ @v_soname_...@$@.$$MAJOR_VER $(LDFLAGS) \
+           -o $...@.$$ver $(OBJ) $(ADDLOBJS) $(LIBS)
 
 #
 # The following rule succeeds, but the result is untested.
 #
-# XXX - OS X installs the library as "libpcap.A.dylib", with that as the
-# install_name, and sets the current version to 1 as well.  VERSION
-# might contain a not-purely-numeric version number, but
-# -current_version requires a purely numeric version, so this won't
-# work with top-of-tree builds.
+# In Mac OS X, the libpcap dylib has the name "libpcap.A.dylib", with
+# its full path as the install_name, and with the compatibility and
+# current version both set to 1.  The compatibility version is set to
+# 1 so that programs built with a newer version of the library will run
+# against older versions; multi-platform software probably will fail if
+# it uses APIs added in the newer version, but Mac OS X-specific software
+# will use weak linking and check at run time whether those APIs are
+# available.
+#
+# We also use "A" as the major version, and 1 as the compatibility version,
+# but set the current version to the value in VERSION, with any non-numeric
+# stuff stripped off (the compatibility and current version must be of the
+# form X[.Y[.Z]], with Y and Z possibly absent, and with all components
+# numeric).
 #
 libpcap.dylib: $(OBJ)
        rm -f libpcap*.dylib
-       $(CC) -dynamiclib -undefined error -o libpcap.`cat 
$(srcdir)/VERSION`.dylib $(OBJ) \
-               -install_name $(libdir)/libpcap.A.dylib \
-               -compatibility_version 1 \
-               -current_version `sed 's/[^0-9.].*$$//' $(srcdir)/VERSION`
+       VER=`cat $(srcdir)/VERSION`; \
+       MAJOR_VER=A; \
+       COMPAT_VER=1; \
+       CURRENT_VER=`sed 's/[^0-9.].*$$//' $(srcdir)/VERSION`; \
+       $(CC) -dynamiclib -undefined error $(LDFLAGS) \
+           -o libpcap.$$VER.dylib $(OBJ) $(ADDLOBJS) $(LIBS) \
+           -install_name $(libdir)/libpcap.$$MAJOR_VER.dylib \
+           -compatibility_version $$COMPAT_VER \
+           -current_version $$CURRENT_VER
+
+#
+# The HP-UX linker manual says that the convention for a versioned library
+# is libXXX.{number}, not libXXX.sl.{number}.  That appears to be the case
+# on at least one HP-UX 11.00 system; libXXX.sl is a symlink to
+# libXXX.{number}.
+#
+# The manual also says "library-level versioning" (think "sonames") was
+# added in HP-UX 10.0.
+#
+# XXX - this assumes we're using the HP linker, rather than the GNU
+# linker, even with GCC.
+#
+libpcap.sl: $(OBJ)
+       @MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \
+       rm -f libpcap.$$MAJOR_VER
+       MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \
+       ld -b $(LDFLAGS) -o libpcap.$$MAJOR_VER +h libpcap.$$MAJOR_VER \
+           $(OBJ) $(ADDLOBJS) $(LIBS)
+
+#
+# AIX is different from everybody else.  A shared library is an archive
+# library with one or more shared-object components.  We still build a
+# normal static archive library on AIX, for the benefit of the traditional
+# scheme of building libpcap and tcpdump in subdirectories of the
+# same directory, with tcpdump statically linked with the libpcap
+# in question, but we also build a shared library as "libpcap.shareda"
+# and install *it*, rather than the static library, as "libpcap.a".
+#
+libpcap.shareda: $(OBJ)
+       @rm -f $@ shr.o
+       $(CC) @V_SHLIB_OPT@ -o shr.o $(OBJ) $(ADDLOBJS) $(LDFLAGS) $(LIBS)
+       ar rc $@ shr.o
+
+#
+# For platforms that don't support shared libraries (or on which we
+# don't support shared libraries).
+#
+libpcap.none:
 
 scanner.c: $(srcdir)/scanner.l
        @rm -f $@
-       ./runlex.sh $(LEX) -o$@ $<
+       $(srcdir)/runlex.sh $(LEX) -o$@ $<
 
 scanner.o: scanner.c tokdefs.h
        $(CC) $(CFLAGS) -c scanner.c
@@ -372,7 +437,13 @@ snprintf.o: $(srcdir)/missing/snprintf.c
 
 version.c: $(srcdir)/VERSION
        @rm -f $@
-       sed -e 's/.*/char pcap_version[] = "&";/' $(srcdir)/VERSION > $@
+       if grep GIT ${srcdir}/VERSION >/dev/null; then \
+               read ver <${srcdir}/VERSION; \
+               echo $$ver | tr -d '\012'; \
+               date +_%Y_%m_%d; \
+       else \
+               cat ${srcdir}/VERSION; \
+       fi | sed -e 's/.*/char pcap_version[] = "&";/' > $@
 
 #
 # NOTE: this really is supposed to be static; importing a string
@@ -383,7 +454,13 @@ version.c: $(srcdir)/VERSION
 #
 version.h: $(srcdir)/VERSION
        @rm -f $@
-       sed -e 's/.*/static const char pcap_version_string[] = "libpcap version 
&";/' $(srcdir)/VERSION > $@
+       if grep GIT ${srcdir}/VERSION >/dev/null; then \
+               read ver <${srcdir}/VERSION; \
+               echo $$ver | tr -d '\012'; \
+               date +_%Y_%m_%d; \
+       else \
+               cat ${srcdir}/VERSION; \
+       fi | sed -e 's/.*/static const char pcap_version_string[] = "libpcap 
version &";/' > $@
 
 bpf_filter.c: $(srcdir)/bpf/net/bpf_filter.c
        rm -f bpf_filter.c
@@ -395,12 +472,13 @@ bpf_filter.o: bpf_filter.c
 #
 # Generate the pcap-config script.
 #
-pcap-config: pcap-config.in Makefile
+pcap-config: $(srcdir)/pcap-config.in
        @rm -f $@ [email protected]
        sed -e 's|@included...@]|$(includedir)|g' \
            -e 's|@libd...@]|$(libdir)|g' \
-           -e 's|@depli...@]|$(DEPLIBS)|g' \
-           pcap-config.in >[email protected]
+           -e 's|@li...@]|$(LIBS)|g' \
+           -e 's|@v_rpath_o...@]|$(V_RPATH_OPT)|g' \
+           $(srcdir)/pcap-config.in >[email protected]
        mv [email protected] $@
        chmod a+x $@
 
@@ -408,16 +486,20 @@ pcap-config: pcap-config.in Makefile
 # Test programs - not built by default, and not installed.
 #
 filtertest: filtertest.c libpcap.a
-       $(CC) $(CFLAGS) -I. -L. -o filtertest filtertest.c libpcap.a
+       $(CC) $(CFLAGS) -I. -L. -o filtertest $(srcdir)/filtertest.c libpcap.a 
$(LIBS)
 
 findalldevstest: findalldevstest.c libpcap.a
-       $(CC) $(CFLAGS) -I. -L. -o findalldevstest findalldevstest.c libpcap.a
+       $(CC) $(CFLAGS) -I. -L. -o findalldevstest $(srcdir)/findalldevstest.c 
libpcap.a $(LIBS)
+
+selpolltest: selpolltest.c libpcap.a
+       $(CC) $(CFLAGS) -I. -L. -o selpolltest $(srcdir)/selpolltest.c 
libpcap.a $(LIBS)
+
+opentest: opentest.c libpcap.a
+       $(CC) $(CFLAGS) -I. -L. -o opentest $(srcdir)/opentest.c libpcap.a 
$(LIBS)
 
-install: libpcap.a pcap-config
+install: install-shared install-archive pcap-config
        [ -d $(DESTDIR)$(libdir) ] || \
            (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir))
-       $(INSTALL_DATA) libpcap.a $(DESTDIR)$(libdir)/libpcap.a
-       $(RANLIB) $(DESTDIR)$(libdir)/libpcap.a
        [ -d $(DESTDIR)$(includedir) ] || \
            (mkdir -p $(DESTDIR)$(includedir); chmod 755 
$(DESTDIR)$(includedir))
        [ -d $(DESTDIR)$(includedir)/pcap ] || \
@@ -430,91 +512,151 @@ install: libpcap.a pcap-config
            (mkdir -p $(DESTDIR)$(mandir)/m...@man_file_formats@; chmod 755 
$(DESTDIR)$(mandir)/m...@man_file_formats@)
        [ -d $(DESTDIR)$(mandir)/m...@man_misc_info@ ] || \
            (mkdir -p $(DESTDIR)$(mandir)/m...@man_misc_info@; chmod 755 
$(DESTDIR)$(mandir)/m...@man_misc_info@)
-       $(INSTALL_DATA) $(srcdir)/pcap/pcap.h \
-           $(DESTDIR)$(includedir)/pcap/pcap.h
-       $(INSTALL_DATA) $(srcdir)/pcap/bpf.h \
-           $(DESTDIR)$(includedir)/pcap/bpf.h
-       $(INSTALL_DATA) $(srcdir)/pcap/namedb.h \
-           $(DESTDIR)$(includedir)/pcap/namedb.h
-       $(INSTALL_DATA) $(srcdir)/pcap/sll.h \
-           $(DESTDIR)$(includedir)/pcap/sll.h
-       $(INSTALL_DATA) $(srcdir)/pcap/usb.h \
-           $(DESTDIR)$(includedir)/pcap/usb.h
-       $(INSTALL_DATA) $(srcdir)/pcap.h $(DESTDIR)$(includedir)/pcap.h
-       $(INSTALL_DATA) $(srcdir)/pcap-bpf.h \
-           $(DESTDIR)$(includedir)/pcap-bpf.h
-       $(INSTALL_DATA) $(srcdir)/pcap-namedb.h \
-           $(DESTDIR)$(includedir)/pcap-namedb.h
+       for i in $(PUBHDR); do \
+               $(INSTALL_DATA) $(srcdir)/$$i \
+                   $(DESTDIR)$(includedir)/$$i; done
+       [ -d $(DESTDIR)$(bindir) ] || \
+           (mkdir -p $(DESTDIR)$(bindir); chmod 755 $(DESTDIR)$(bindir))
        $(INSTALL_PROGRAM) pcap-config $(DESTDIR)$(bindir)/pcap-config
        for i in $(MAN1); do \
                $(INSTALL_DATA) $(srcdir)/$$i \
                    $(DESTDIR)$(mandir)/man1/$$i; done
-       for i in $(MAN3PCAP); do \
+       for i in $(MAN3PCAP_NOEXPAND); do \
                $(INSTALL_DATA) $(srcdir)/$$i \
                    $(DESTDIR)$(mandir)/man3/$$i; done
+       for i in $(MAN3PCAP_EXPAND:.in=); do \
+               $(INSTALL_DATA) $$i \
+                   $(DESTDIR)$(mandir)/man3/$$i; done
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_description.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_name.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_description.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_dump_fopen.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_dump_open.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_dump_fopen.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_perror.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_geterr.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_perror.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_sendpacket.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_inject.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_sendpacket.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_dispatch.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_loop.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_dispatch.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_minor_version.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_major_version.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_minor_version.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_next.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_next_ex.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_next.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_fopen_offline.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_open_offline.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_fopen_offline.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_getnonblock.3pcap
        ln $(DESTDIR)$(mandir)/man3/pcap_setnonblock.3pcap \
                 $(DESTDIR)$(mandir)/man3/pcap_getnonblock.3pcap
        for i in $(MANFILE); do \
-               $(INSTALL_DATA) $(srcdir)/`echo $$i | sed 
's/.manfile.in/.manfile/'` \
+               $(INSTALL_DATA) `echo $$i | sed 's/.manfile.in/.manfile/'` \
                    $(DESTDIR)$(mandir)/m...@man_file_formats@/`echo $$i | sed 
's/.manfile.in/....@man_file_formats@/'`; done
        for i in $(MANMISC); do \
-               $(INSTALL_DATA) $(srcdir)/`echo $$i | sed 
's/.manmisc.in/.manmisc/'` \
+               $(INSTALL_DATA) `echo $$i | sed 's/.manmisc.in/.manmisc/'` \
                    $(DESTDIR)$(mandir)/m...@man_misc_info@/`echo $$i | sed 
's/.manmisc.in/....@man_misc_info@/'`; done
 
 install-shared: install-shared-$(DYEXT)
 install-shared-so: libpcap.so
-       $(INSTALL_PROGRAM) libpcap.so.`cat VERSION` 
$(DESTDIR)$(libdir)/libpcap.so.`cat VERSION`
+       [ -d $(DESTDIR)$(libdir) ] || \
+           (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir))
+       VER=`cat $(srcdir)/VERSION`; \
+       MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \
+       $(INSTALL_PROGRAM) libpcap.so.$$VER 
$(DESTDIR)$(libdir)/libpcap.so.$$VER; \
+       ln -sf libpcap.so.$$VER $(DESTDIR)$(libdir)/libpcap.so.$$MAJOR_VER; \
+       ln -sf libpcap.so.$$MAJOR_VER $(DESTDIR)$(libdir)/libpcap.so
 install-shared-dylib: libpcap.dylib
-       $(INSTALL_PROGRAM) libpcap.`cat VERSION`.dylib 
$(DESTDIR)$(libdir)/libpcap.`cat VERSION`.dylib
-       VER=`cat VERSION`; cd $(DESTDIR)$(libdir) && ln -sf libpcap.$$VER.dylib 
libpcap.A.dylib;  ln -sf libpcap.A.dylib libpcap.dylib
+       [ -d $(DESTDIR)$(libdir) ] || \
+           (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir))
+       VER=`cat $(srcdir)/VERSION`; \
+       MAJOR_VER=A; \
+       $(INSTALL_PROGRAM) libpcap.$$VER.dylib 
$(DESTDIR)$(libdir)/libpcap.$$VER.dylib; \
+       ln -sf libpcap.$$VER.dylib 
$(DESTDIR)$(libdir)/libpcap.$$MAJOR_VER.dylib; \
+       ln -sf libpcap.$$MAJOR_VER.dylib $(DESTDIR)$(libdir)/libpcap.dylib
+install-shared-sl: libpcap.sl
+       [ -d $(DESTDIR)$(libdir) ] || \
+           (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir))
+       MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \
+       $(INSTALL_PROGRAM) libpcap.$$MAJOR_VER $(DESTDIR)$(libdir)
+       ln -sf libpcap.$$MAJOR_VER $(DESTDIR)$(libdir)/libpcap.sl
+install-shared-shareda: libpcap.shareda
+       #
+       # AIX shared libraries are weird.  They're archive libraries
+       # with one or more shared object components.
+       #
+       [ -d $(DESTDIR)$(libdir) ] || \
+           (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir))
+       $(INSTALL_PROGRAM) libpcap.shareda $(DESTDIR)$(libdir)/libpcap.a
+install-shared-none:
 
-uninstall:
+install-archive: install-archive-$(DYEXT)
+install-archive-so install-archive-dylib install-archive-sl 
install-archive-none: libpcap.a
+       #
+       # Most platforms have separate suffixes for shared and
+       # archive libraries, so we install both.
+       #
+       [ -d $(DESTDIR)$(libdir) ] || \
+           (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir))
+       $(INSTALL_DATA) libpcap.a $(DESTDIR)$(libdir)/libpcap.a
+       $(RANLIB) $(DESTDIR)$(libdir)/libpcap.a
+install-archive-shareda:
+       #
+       # AIX, however, doesn't, so we don't install the archive
+       # library on AIX.
+       #
+
+uninstall: uninstall-shared
        rm -f $(DESTDIR)$(libdir)/libpcap.a
-       rm -f $(DESTDIR)$(includedir)/pcap/pcap.h
-       rm -f $(DESTDIR)$(includedir)/pcap/bpf.h
-       rm -f $(DESTDIR)$(includedir)/pcap/namedb.h
-       rm -f $(DESTDIR)$(includedir)/pcap/sll.h
-       rm -f $(DESTDIR)$(includedir)/pcap/usb.h
+       for i in $(PUBHDR); do \
+               rm -f $(DESTDIR)$(includedir)/$$i; done
        -rmdir $(DESTDIR)$(includedir)/pcap
-       rm -f $(DESTDIR)$(includedir)/pcap.h
-       rm -f $(DESTDIR)$(includedir)/pcap-bpf.h
-       rm -f $(DESTDIR)$(includedir)/pcap-namedb.h
+       rm -f $(DESTDIR)/$(bindir)/pcap-config
        for i in $(MAN1); do \
                rm -f $(DESTDIR)$(mandir)/man1/$$i; done
        for i in $(MAN3PCAP); do \
                rm -f $(DESTDIR)$(mandir)/man3/$$i; done
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_description.3pcap
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_dump_fopen.3pcap
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_perror.3pcap
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_sendpacket.3pcap
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_dispatch.3pcap
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_minor_version.3pcap
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_next.3pcap
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_fopen_offline.3pcap
-       rm -f  $(DESTDIR)$(mandir)/man3/pcap_getnonblock.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_datalink_val_to_description.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_dump_fopen.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_perror.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_sendpacket.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_dispatch.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_minor_version.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_next.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_fopen_offline.3pcap
+       rm -f $(DESTDIR)$(mandir)/man3/pcap_getnonblock.3pcap
        for i in $(MANFILE); do \
                rm -f $(DESTDIR)$(mandir)/m...@man_file_formats@/`echo $$i | 
sed 's/.manfile.in/....@man_file_formats@/'`; done
        for i in $(MANMISC); do \
                rm -f $(DESTDIR)$(mandir)/m...@man_misc_info@/`echo $$i | sed 
's/.manmisc.in/....@man_misc_info@/'`; done
 
+uninstall-shared: uninstall-shared-$(DYEXT)
+uninstall-shared-so:
+       VER=`cat $(srcdir)/VERSION`; \
+       MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \
+       rm -f $(DESTDIR)$(libdir)/libpcap.so.$$VER; \
+       rm -f $(DESTDIR)$(libdir)/libpcap.so.$$MAJOR_VER; \
+       rm -f $(DESTDIR)$(libdir)/libpcap.so
+uninstall-shared-dylib:
+       VER=`cat $(srcdir)/VERSION`; \
+       MAJOR_VER=A; \
+       rm -f $(DESTDIR)$(libdir)/libpcap.$$VER.dylib; \
+       rm -f $(DESTDIR)$(libdir)/libpcap.$$MAJOR_VER.dylib; \
+       rm -f $(DESTDIR)$(libdir)/libpcap.dylib
+uninstall-shared-sl:
+       MAJOR_VER=`sed 's/\([0-9][0-9]*\)\..*/\1/' $(srcdir)/VERSION`; \
+       rm -f $(DESTDIR)$(libdir)/libpcap.$$MAJOR_VER; \
+       rm -f $(DESTDIR)$(libdir)/libpcap.sl
+uninstall-shared-shareda:
+       rm -f $(DESTDIR)$(libdir)/libpcap.a
+uninstall-shared-none:
+
 clean:
-       rm -f $(CLEANFILES) libpcap*.dylib libpcap.so*
+       rm -f $(CLEANFILES)
 
 distclean: clean
        rm -f Makefile config.cache config.log config.status \
@@ -530,7 +672,7 @@ packaging/pcap.spec: packaging/pcap.spec
        RPMVERSION=`cat VERSION | sed s/-.*//g`; \
                sed -e s/@VERSION@/$$RPMVERSION/ -e s/@NAME@/libpcap-`cat 
VERSION`/ $<   > $@
 
-releasetar:
+releasetar: 
        @cwd=`pwd` ; dir=`basename $$cwd` ; name=$(PROG)-`cat VERSION` ; \
           mkdir $$name; \
           tar cf - $(CSRC) $(HDR) $(MAN1) $(MAN3PCAP_EXPAND) \

Modified: head/contrib/libpcap/README
==============================================================================
--- head/contrib/libpcap/README Fri Oct 29 18:41:09 2010        (r214517)
+++ head/contrib/libpcap/README Fri Oct 29 18:43:23 2010        (r214518)
@@ -1,19 +1,17 @@
-@(#) $Header: /tcpdump/master/libpcap/README,v 1.30.4.3 2008-10-17 10:39:20 
ken Exp $ (LBL)
+@(#) $Header: /tcpdump/master/libpcap/README,v 1.34 2008-12-14 19:44:14 guy 
Exp $ (LBL)
 
-LIBPCAP 1.0.0
+LIBPCAP 1.x.y
 
 www.tcpdump.org
 
 Please send inquiries/comments/reports to:
        [email protected]
 
-Anonymous CVS is available via:
-       cvs -d :pserver:[email protected]:/tcpdump/master login
-       (password "anoncvs")
-       cvs -d :pserver:[email protected]:/tcpdump/master checkout libpcap
+Anonymous Git is available via:
+       git clone git://bpf.tcpdump.org/libpcap
 
-Version 1.0.0 of LIBPCAP can be retrieved with the CVS tag "libpcap_1_0":
-       cvs -d :pserver:[email protected]:/tcpdump/master checkout -r 
libpcap_1_0 libpcap
+Version 1.x.y of LIBPCAP can be retrieved with the CVS tag 
"libpcap_1_{x}rel{y}":
+       cvs -d :pserver:[email protected]:/tcpdump/master checkout -r 
libpcap_1_{x}rel{y} libpcap
 
 Please submit patches against the master copy to the libpcap project on
 sourceforge.net.
@@ -80,10 +78,10 @@ information on configuring that option.
 Note to Linux distributions and *BSD systems that include libpcap:
 
 There's now a rule to make a shared library, which should work on Linux 
-and *BSD (and OS X).
+and *BSD, among other platforms.
 
 It sets the soname of the library to "libpcap.so.1"; this is what it 
-should be, *NOT* libpcap.so.1.0 or libpcap.so.1.0.0 or something such as 
+should be, *NOT* libpcap.so.1.x or libpcap.so.1.x.y or something such as 
 that.
 
 We've been maintaining binary compatibility between libpcap releases for 

Copied: head/contrib/libpcap/README.Win32 (from r214514, 
vendor/libpcap/dist/README.Win32)
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ head/contrib/libpcap/README.Win32   Fri Oct 29 18:43:23 2010        
(r214518, copy of r214514, vendor/libpcap/dist/README.Win32)
@@ -0,0 +1,46 @@
+Under Win32, libpcap is integrated in the WinPcap packet capture system. 
+WinPcap provides a framework that allows libpcap to capture the packets 
+under Windows 95, Windows 98, Windows ME, Windows NT 4, Windows 2000 
+and Windows XP.
+WinPcap binaries and source code can be found at http://winpcap.polito.it: 
+they include also a developer's pack with all the necessary to compile 
+libpcap-based applications under Windows.
+
+How to compile libpcap with Visual Studio
+-----------------------------------------
+
+In order to compile libpcap you will need:
+
+- version 6 (or higher) of Microsoft Visual Studio
+- The November 2001 (or later) edition of Microsoft Platform 
+Software Development Kit (SDK), that contains some necessary includes 
+for IPv6 support. You can download it from http://www.microsoft.com/sdk
+- the latest WinPcap sources from http://winpcap.polito.it/install 
+
+The WinPcap source code already contains a recent (usually the latest 
+stable) version of libpcap. If you need to compile a different one, 
+simply download it from www.tcpdump.org and copy the sources in the 
+winpcap\wpcap\libpcap folder of the WinPcap distribution. If you want to
+compile a libpcap source retrieved from the tcpdump.org Git, you will 
+have to create the scanner and the grammar by hand (with lex and yacc) 
+or with the cygnus makefile, since The Visual Studio project is not able
+to build them.
+
+Open the project file winpcap\wpcap\prj\wpcap.dsw with Visual Studio and 
+build wpcap.dll. wpcap.lib, the library file to link with the applications, 
+will be generated in winpcap\wpcap\lib\. wpcap.dll will be generated in 
+winpcap\wpcap\prj\release or winpcap\wpcap\prj\debug depending on the type 
+of binary that is being created.
+
+How to compile libpcap with Cygnus
+----------------------------------
+
+To build wpcap.dll, cd to the directory WPCAP/PRJ of the WinPcap source code 
+distribution and type "make". libwpcap.a, the library file to link with the 
+applications, will be generated in winpcap\wpcap\lib\. wpcap.dll will be 
+generated in winpcap\wpcap\prj.
+
+Remember, you CANNOT use the MSVC-generated .lib files with gcc, use 
+libwpcap.a instead.
+
+"make install" installs wpcap.dll in the Windows system folder.

Copied: head/contrib/libpcap/README.aix (from r214514, 
vendor/libpcap/dist/README.aix)
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ head/contrib/libpcap/README.aix     Fri Oct 29 18:43:23 2010        
(r214518, copy of r214514, vendor/libpcap/dist/README.aix)
@@ -0,0 +1,81 @@
+Using BPF:
+
+(1) AIX 4.x's version of BPF is undocumented and somewhat unstandard; the
+    current BPF support code includes changes that should work around
+    that; it appears to compile and work on at least one AIX 4.3.3
+    machine.
+
+    Note that the BPF driver and the "/dev/bpf" devices might not exist
+    on your machine; AIX's tcpdump loads the driver and creates the
+    devices if they don't already exist.  Our libpcap should do the
+    same, and the configure script should detect that it's on an AIX
+    system and choose BPF even if the devices aren't there.
+
+(2) If libpcap doesn't compile on your machine when configured to use
+    BPF, or if the workarounds fail to make it work correctly, you
+    should send to [email protected] a detailed bug
+    report (if the compile fails, send us the compile error messages;
+    if it compiles but fails to work correctly, send us as detailed as
+    possible a description of the symptoms, including indications of the
+    network link-layer type being wrong or time stamps being wrong).
+
+    If you fix the problems yourself, please submit a patch to
+
+       http://sourceforge.net/projects/libpcap/
+
+    so we can incorporate them into the next release.
+
+    If you don't fix the problems yourself, you can, as a workaround,
+    make libpcap use DLPI instead of BPF.
+
+    This can be done by specifying the flag:
+
+       --with-pcap=dlpi
+
+    to the "configure" script for libpcap.
+
+If you use DLPI:
+
+(1) It is a good idea to have the latest version of the DLPI driver on
+    your system, since certain versions may be buggy and cause your AIX
+    system to crash.  DLPI is included in the fileset bos.rte.tty.  I
+    found that the DLPI driver that came with AIX 4.3.2 was buggy, and
+    had to upgrade to bos.rte.tty 4.3.2.4:
+
+           lslpp -l bos.rte.tty
+
+           bos.rte.tty     4.3.2.4  COMMITTED  Base TTY Support and Commands
+
+    Updates for AIX filesets can be obtained from:
+    ftp://service.software.ibm.com/aix/fixes/
+
+    These updates can be installed with the smit program.
+
+(2) After compiling libpcap, you need to make sure that the DLPI driver
+    is loaded.  Type:
+
+           strload -q -d dlpi
+
+    If the result is:
+
+           dlpi: yes
+
+    then the DLPI driver is loaded correctly.
+
+    If it is:
+
+           dlpi: no
+
+    Then you need to type:
+
+           strload -f /etc/dlpi.conf
+ 
+    Check again with strload -q -d dlpi that the dlpi driver is loaded.  
+
+    Alternatively, you can uncomment the lines for DLPI in
+    /etc/pse.conf and reboot the machine; this way DLPI will always
+    be loaded when you boot your system.
+
+(3) There appears to be a problem in the DLPI code in some versions of
+    AIX, causing a warning about DL_PROMISC_MULTI failing; this might
+    be responsible for DLPI not being able to capture outgoing packets.

Copied: head/contrib/libpcap/README.dag (from r214514, 
vendor/libpcap/dist/README.dag)
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ head/contrib/libpcap/README.dag     Fri Oct 29 18:43:23 2010        
(r214518, copy of r214514, vendor/libpcap/dist/README.dag)
@@ -0,0 +1,114 @@
+
+The following instructions apply if you have a Linux or FreeBSD platform and
+want libpcap to support the DAG range of passive network monitoring cards from
+Endace (http://www.endace.com, see below for further contact details).
+
+1) Install and build the DAG software distribution by following the
+instructions supplied with that package. Current Endace customers can download
+the DAG software distibution from https://www.endace.com
+
+2) Configure libcap. To allow the 'configure' script to locate the DAG
+software distribution use the '--with-dag' option:
+
+        ./configure --with-dag=DIR
+
+Where DIR is the root of the DAG software distribution, for example
+/var/src/dag. If the DAG software is correctly detected 'configure' will
+report:
+
+        checking whether we have DAG API... yes
+
+If 'configure' reports that there is no DAG API, the directory may have been
+incorrectly specified or the DAG software was not built before configuring
+libpcap.
+
+See also the libpcap INSTALL.txt file for further libpcap configuration
+options.
+
+Building libpcap at this stage will include support for both the native packet
+capture stream (linux or bpf) and for capturing from DAG cards. To build
+libpcap with only DAG support specify the capture type as 'dag' when
+configuring libpcap:
+
+        ./configure --with-dag=DIR --with-pcap=dag
+
+Applications built with libpcap configured in this way will only detect DAG
+cards and will not capture from the native OS packet stream.
+
+----------------------------------------------------------------------
+
+Libpcap when built for DAG cards against dag-2.5.1 or later releases:
+
+Timeouts are supported. pcap_dispatch() will return after to_ms milliseconds
+regardless of how many packets are received. If to_ms is zero pcap_dispatch()
+will block waiting for data indefinitely.
+
+pcap_dispatch() will block on and process a minimum of 64kB of data (before
+filtering) for efficiency. This can introduce high latencies on quiet
+interfaces unless a timeout value is set. The timeout expiring will override
+the 64kB minimum causing pcap_dispatch() to process any available data and
+return.
+
+pcap_setnonblock is supported. When nonblock is set, pcap_dispatch() will
+check once for available data, process any data available up to count, then
+return immediately.
+
+pcap_findalldevs() is supported, e.g. dag0, dag1...
+
+Some DAG cards can provide more than one 'stream' of received data.
+This can be data from different physical ports, or separated by filtering
+or load balancing mechanisms. Receive streams have even numbers, e.g.
+dag0:0, dag0:2 etc. Specifying transmit streams for capture is not supported.
+

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "[email protected]"

Reply via email to