Cross-compiling Libraries Error


#1

Hello all,

I’m trying to cross-compile the “boost” libraries for the Airlink FX30.
For starters, I’ve created a user-config.jam file in my home directory with the following contents (my apologies on this being a bit hard to read, I had to use absolute paths or else the cross-compiler would complain):

using gcc : arm : /home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++ : <cxxflags>--sysroot=/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/armv7a-vfp-neon-poky-linux-gnueabi <include>/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/armv7a-vfp-neon-poky-linux-gnueabi <linkflags>-L/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/armv7a-vfp-neon-poky-linux-gnueabi/usr/lib -L/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/armv7a-vfp-neon-poky-linux-gnueabi/usr/local/lib <compileflags>-v ;

As you can see I’ve set the sysroot to the directory that is the / directory of the disk image. I’ve also set library paths to the disk image’s /usr/lib & /usr/local/lib directories. I also tried several variations on setting the include path to point to the disk image, but I run into issues when compiling the boost libraries.

I put the following code on the command line:
./bootstrap.sh --without-libraries=python
./b2 --debug-configuration toolset=gcc-arm -q

Then it will compile, but when the compiler hits the alloc_lib.c file, it gives an error. It can’t find a header file (in this case h I find strange because the header file is available on the disk image in multiple directories like /usr/include/

What struck me as odd is that the include search for this file has a lot shorter search list than for other files. It only searches in the next directories:

/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/../../lib/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/4.9.1/include
/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/../../lib/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/4.9.1/include-fixed
End of search list.

But when, for example, searching for headers for libboost_atomic, it looks in more directories:

 #include "..." search starts here:
 #include <...> search starts here:
.
/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/armv7a-vfp-neon-poky-linux-gnueabi/usr/include
/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/../../lib/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/4.9.1/include
/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/../../lib/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/4.9.1/include-fixed
/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/armv7a-vfp-neon-poky-linux-gnueabi/usr/include/c++/4.9.1
/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/armv7a-vfp-neon-poky-linux-gnueabi/usr/include/c++/4.9.1/arm-poky-linux-gnueabi
/home/developer/legato/packages/legato.toolchain.1.7.3.SWI9X15Y_07112100-wp85-wp750x-native-x86_64-201701091132/resources/native/sysroots/armv7a-vfp-neon-poky-linux-gnueabi/usr/include/c++/4.9.1/backward

Can anybody help me with this problem?