tcpdump mailing list archives

Re: pcap_lib_version problem while installing DAQ


From: Guy Harris <guy () alum mit edu>
Date: Tue, 28 Dec 2010 11:03:42 -0800


On Dec 27, 2010, at 10:26 PM, Appaji_Peruri wrote:

I am having a problem while installing DAQ which is used by snort . DAQ package is searching for the function 
pcap_lib_version and returning the following error .

checking for pcap_lib_version... checking for pcap_lib_version in -lpcap... no

   ERROR!  Libpcap library version >= 1.0.0 not found.
   Get it from http://www.tcpdump.org

My query is whether libpcap 1.1 includes the above function or not .

Yes, it does.  It has been in libpcap since one of the 0.8.x releases, and has never been removed.

if so how to verify the same.

As you say "libpcap" rather than "WinPcap", I'm assuming this is on some flavor of UN*X (Solaris, Linux, Mac OS X, 
HP-UX, AIX, *BSD, etc.) rather than on Windows.

Step 1: find where the libpcap library is installed.

Step 2: run "nm -p" on that library and pipe the result through "grep pcap_lib_version".

That should show that it does, in fact, define pcap_lib_version().

The problem here is that DAQ's configure script is buggy - it appears to be assuming that if you're building a program 
with -lpcap, you won't, for example, have to build it with -lnl.  That assumption is not necessarily true; if, on 
Linux, you're linking with a static version of libpcap, for example, or if you're linking with a dynamic version that 
wasn't itself linked with -lnl, you might also have to link with -lnl, as libpcap uses -lnl.  Similarly, it might be 
assuming that you don't have to build it with -lsocket and -lnsl, but that's not true on Solaris.

Are you doing this on some Linux distribution?  If so, what distribution is it, and what version of that distribution 
is this?

If not, what operating system are you doing this on, and what version of that operating system is it?

Did that version of that operating system/distribution come with libpcap?  If so, are you using the version of libpcap 
that came with the operating system, or did you build and install libpcap yourself?  (If the OS didn't come with 
libpcap, you presumably built and installed it yourself.)

If you built and installed libpcap yourself, where is it installed - and did you build and install a shared (dynamic) 
version, or just a static version?

If it came with the OS, does it come with a shared version, a static version, or both?-
This is the tcpdump-workers list.
Visit https://cod.sandelman.ca/ to unsubscribe.


Current thread: