Hi,
i have a linksys WRT54GL v1.1 with WHITE RUSSIAN (0.9)  and i want to cross-compile a program with the library libpcap and libpthread.
I want use my WRT54GL like monitor to sniff packet wireless to command an Access Point to start Handoff/Handover for the associated mobile station to another Access Point and my program  include many headers file and c files like :

monitor.c
monitor_caputure.c
monitor_sender.c
monitor_receiver.c
etc...

And their headers :

monitor_capture.h
monitor_sender.h
monitor_receiver.h
etc..

I download from site of Linksys the toolchain :

http://www.linksysbycisco.com/IT/it/sup … ku=#WRT54G

I install libpcap-0.9.6 on my Ubuntu

I download WRT54GL-US_v4.30.13.tgz in Desktop
tar xvzf WRT54GL-US_v4.30.13.tgz
cd WRT54GL-US_v4.30.13/tools/

then i copy the dir brcm in /opt

cd /opt/brcm/hndtools-mipsel-linux/bin

set the PATH with  export PATH="$PATH:$PWD"

also cd /opt/brcm/hndtools-mipsel-uclibc/bin

set the PATH with  export PATH="$PATH:$PWD"

and go in my directory withe the files to cross-compile and do:

mipsel-uclibc-gcc monitor.c monitor_list.c monitor_receiver.c ......  -o monitor -L /home/peppe/WRT54GL-US_v4.30.13/tools-mipsel-uclibc/lib/libpthread.a -static -lpthread -L /usr/lib/libpcap.a -I /usr/include/ -static -lpcap



but i have this error :
/opt/brcm/hndtools-mipsel-linux/bin/../lib/gcc-lib/mipsel-linux/3.2.3/../../../../mipsel-linux/bin/ld: cannot find -lpcap
collect2: ld returned 1 exit status

The if i cross-compile e simple file hello.c with:

mipsel-uclibc-gcc hello.c -o hello

compile ok and when i copy this file in WRT54GL run .
Have someone an idea to solve this problems ? where i mistake ? please help me  sad