Errors cross compiling GMP
Sri Yogesh Dorbala
yogeshdorbala at gmail.com
Thu Oct 1 07:19:30 UTC 2015
I have followed this How-to
<https://how-to-build-for-arm.wikispaces.com/gcc-4_8_2> and g,h section of
cross compiling tutorial
<http://pmc.polytechnique.fr/pagesperso/dc/arm-en.html> for cross compiling
GMP. This is the error message(last part) I get after running make.
/usr/bin/ld: skipping incompatible
/home/yogi/workbench/gcc-4.8.2/arm/lib/libmpfr.so when searching for
-lmpfr/usr/bin/ld: skipping incompatible
/home/yogi/workbench/gcc-4.8.2/arm/lib/libmpfr.a when searching for
-lmpfr/usr/bin/ld: skipping incompatible
/home/yogi/workbench/gcc-4.8.2/arm/lib/libmpfr.so when searching for
-lmpfr/usr/bin/ld: skipping incompatible
/home/yogi/workbench/gcc-4.8.2/arm/lib/libmpfr.a when searching for
-lmpfr/usr/bin/ld: skipping incompatible
/home/yogi/workbench/gcc-4.8.2/arm/lib/libgmp.a when searching for
-lgmp/usr/bin/ld: skipping incompatible
/home/yogi/workbench/gcc-4.8.2/arm/lib/libgmp.a when searching for
-lgmp/home/yogi/workbench/gcc-4.8.2/xtools/build/final-gcc-cross/./mpc/src/.libs/libmpc.a(pow.o):
In function `mpc_pow_exact':/home/yogi/workbench/gcc-4.8.2/xtools/src/gcc-4.8.2/mpc/src/pow.c:123:
undefined reference to
`mpfr_get_z_exp'/home/yogi/workbench/gcc-4.8.2/xtools/src/gcc-4.8.2/mpc/src/pow.c:135:
undefined reference to
`mpfr_get_z_exp'/home/yogi/workbench/gcc-4.8.2/xtools/src/gcc-4.8.2/mpc/src/pow.c:143:
undefined reference to `mpfr_get_z_exp'
collect2: error: ld returned 1 exit status
make[2]: *** [cc1] Error 1
make[2]: Leaving directory
`/home/yogi/workbench/gcc-4.8.2/xtools/build/final-gcc-cross/gcc'
make[1]: *** [all-gcc] Error 2
make[1]: Leaving directory
`/home/yogi/workbench/gcc-4.8.2/xtools/build/final-gcc-cross'
How to fix it?
Also, any tutorial link on cross compiling GMP to ARM would be highly
helpful.
Thanks!
More information about the gmp-discuss
mailing list