LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   pcap_parse (https://www.linuxquestions.org/questions/linux-newbie-8/pcap_parse-861487/)

joeman 02-08-2011 03:44 PM

pcap_parse
 
Hi every body
I am new to linux,could you please some one tell me know how to fix this error:
I wanna compile a C program which niffs the network for arp packets and prints them out ,I keep getting this error:

undefined reference to `pcap_parse'
I have installed every thing new version of pcap ,...
thanks if anybody knows

TB0ne 02-08-2011 04:40 PM

Quote:

Originally Posted by joeman (Post 4252355)
Hi every body
I am new to linux,could you please some one tell me know how to fix this error:
I wanna compile a C program which niffs the network for arp packets and prints them out ,I keep getting this error:

undefined reference to `pcap_parse'
I have installed every thing new version of pcap ,...
thanks if anybody knows

You don't say what version/distro of Linux you're using, but you need the PCAP development libraries installed, before you can build programs against them. Install libpcap for your distro.

A search on this site yields results as well:
http://www.linuxquestions.org/questi..._parse-842348/

joeman 02-08-2011 04:46 PM

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=10.10
DISTRIB_CODENAME=maverick
DISTRIB_DESCRIPTION="Ubuntu 10.10"
I am using this version
I have installed libnet-1.1.5 and libcap-1.1.1
Thank you for reply


Quote:

Originally Posted by TB0ne (Post 4252398)
You don't say what version/distro of Linux you're using, but you need the PCAP development libraries installed, before you can build programs against them. Install libpcap for your distro.

A search on this site yields results as well:
http://www.linuxquestions.org/questi..._parse-842348/


joeman 02-08-2011 05:02 PM

do u know any thing about build-essential?my tutor told me to install that ,I have installed that ,but it didn't help

Quote:

Originally Posted by joeman (Post 4252402)
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=10.10
DISTRIB_CODENAME=maverick
DISTRIB_DESCRIPTION="Ubuntu 10.10"
I am using this version
I have installed libnet-1.1.5 and libcap-1.1.1
Thank you for reply


joeman 02-09-2011 06:55 PM

It solved
I removed the libpcap-1.1.1
and installed libpcap0.8-dev


All times are GMT -5. The time now is 12:30 AM.