OESF Portables Forum
Model Specific Forums => Sharp Zaurus => Zaurus - pdaXrom => Topic started by: Ostots on June 23, 2005, 05:54:17 pm
-
Hello,
I am trying to compile an app for Z and later I want modifi the app for me...
I have downloaded :
http://mirror1.pdaxrom.org/archive/rc5/pda...ftfloat.tar.bz2 (http://mirror1.pdaxrom.org/archive/rc5/pdaxromsdk-1.1.0-softfloat.tar.bz2)
and untar this at /opt/arm
to compile from source code dir I do this:
$ /opt/arm/runzgcc-vfp.sh
pdaXrom cross developer tools 1.1.0 softfloat(VFP)
Type 'exit' for leave shell.
Cross prefix is 'armv5tel-linux-'
Predefined variables:
X11INC - X11 include path
X11LIB - X11 libraries path
QTDIR - QT basedir path
sh-3.00$
in this shell I exec this lines:
sh-3.00$ cat makeme
#!/bin/sh
armv5tel-linux-gcc inetflash.c -o inetflash -lpcap
armv5tel-linux-strip inetflash
then I have these errors:
sh-3.00$ ./makeme
inetflash.c:4:18: pcap.h: No such file or directory
inetflash.c:25: warning: `struct pcap_pkthdr' declared inside parameter list
inetflash.c:25: warning: its scope is only this definition or declaration, which is probably not what you want
inetflash.c: In function `main':
inetflash.c:53: error: `PCAP_ERRBUF_SIZE' undeclared (first use in this function)
inetflash.c:53: error: (Each undeclared identifier is reported only once
inetflash.c:53: error: for each function it appears in.)
inetflash.c:54: error: `pcap_t' undeclared (first use in this function)
inetflash.c:54: error: `descr' undeclared (first use in this function)
inetflash.c:56: error: storage size of `hdr' isn't known
inetflash.c:62: warning: assignment makes pointer from integer without a cast
These are my questions: What I must to do? cp my pcap.h to somewhere at /opt/arm... ?
and what means "-lpcap" at armv5tel-linux-gcc command?
Thanks!
-
"-lpcap" tells the gcc compiler that it should include the pcap shared library in the the program (technically it doesn't include it just makes pointers to the shared library functions) to get these functions pcap.h needs to be available for the complier and libpcap.so needs to be available for the linker.
.h files are normally found in the /include or /usr/include folder - not sure of the exact set up for the pdax sdk
Stu