Happy New Year to all!
I am currently trying to cross-compile a version of OpenJDK/IcedTea
for ARM and I am running into a few issues. Since there is no easy way
of managing third party libraries for cross-compilation under debian
(i.e. installing libjpeg for arm on a x86 host) I am compiling and
linking against lib and headers that I export from a native arm debian
machine. For that, I specify which LDFLAGS and CPPFLAGS to use while
compiling as follows:
/LD_LIBRARY_PATH="/usr/arm-linux-gnueabi/lib/" ;
LDFLAGS="-L/usr/local/dev/dev-headers-armel/usr/lib" ;
CPPFLAGS="-I/usr/local/dev/dev-headers-armel/usr/include" ;
./configure --build=x86 --host=arm-linux-gnueabi [...]/
Unfortunately, this fails to compile even the simplest c file. The
config.log gives me the following error:
/ configure:3066: checking for C compiler default output file name
configure:3093: arm-linux-gnueabi-gcc
-I/usr/local/dev/dev-headers-armel/usr/include
-L/usr/local/dev/dev-headers-armel/usr/lib conftest.c >&5
/usr/lib/gcc/arm-linux-gnueabi/4.3.2/../../../../arm-linux-gnueabi/bin/ld:
skipping incompatible /lib/libc.so.6 when searching for /lib/libc.so.6
/usr/lib/gcc/arm-linux-gnueabi/4.3.2/../../../../arm-linux-gnueabi/bin/ld:
cannot find /lib/libc.so.6
collect2: ld returned 1 exit status
[...]
configure:3141: error: C compiler cannot create executables/
Does anyone have an idea of what the issue might be? Is there a
better, more common way of managing third party libs for
cross-compilation?
Thanks,
Martin