[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: libpcap-dev confusion



[talbertb@comcast.net]
> Specifically, the errors I get are below:
>  
> Undefined reference to ?pcap_dump?
> Undefined reference to ?pcap_open_dead?
> Undefined reference to ?pcap_dump_open?

I suspect the libpcap header is missing the magic phrases to make it
includable in C++.  Try to protect the include statement with 'extern
"C" {' and '}', to tell the compiler to treat the header as a header
for C functions.

(Just a random idea based on my experience with C and C++ linker
problems. :)

If this do not help, you should make a minimal code example
demonstrating the problem, or make some source available for testing.



Reply to: