[fpc-pascal] FPC on ARM (eg Zaurus)

Den Jean geeken at pandora.be
Mon Nov 1 05:52:29 CET 2004


I am trying to cross-compile a program a bit more
complicated than Hello World and I have the following problem.

ppcarm uses the wrong libraries because it uses some default lib paths
first before it uses the library paths added with -Fl


ppcarm -Sd -XParm-linux- -k'-z nodefaultlib'  -vt -Fl/opt/Embedix/tools/arm-linux/lib* -Fl/opt/Embedix/tools/lib/gcc-lib/arm-linux/2.95.2 test_dl.pas

gives error:
/usr/lib/crti.o: could not read symbols: File in wrong format

which is true,  /opt/Embedix/tools/arm-linux/lib/crti.o should be used

the -vt options tells me that /usr/lib is searched first.

Using library path: /lib/
Using library path: /usr/lib/
Using library path: /usr/X11R6/lib/
Using library path: /opt/Embedix/tools/arm-linux/lib/
.... etc ...

With  -k'-z nodefaultlib' i tried in vain to omit searching for default libraries

So, how can I tell ppcarm not to use /usr/lib ?

When fiddling with LD_LIBRARY_PATH, I found out that 
the compiler programs ofcourse cannot cope with a library path to arm libs.

kind regards,
Den Jean

More information about the fpc-pascal mailing list