Thanks so much, Jürgen!!! -----Original Message----- From: boost-users-bounces@lists.boost.org [mailto:boost-users-bounces@lists.boost.org] On Behalf Of Jürgen Hunold Sent: Tuesday, July 26, 2011 10:47 AM To: boost-users@lists.boost.org Subject: Re: [Boost-users] [cross-compiling] Hi Donald, On Tuesday, 26. July 2011 18:50:24 Wilde, Donald S wrote:
We have a somewhat tricky cross-compile, and I’m hoping I can get some feedback to help me be sure that I’m doing this right.
In my user-config.jam, I (think I) need to put the following line:
Using gcc : 4.5.1 : : “/path/to/target/compiler” <compileflags> -I/path/to/sdk/includes <cxxflags> -std=c++0x <cflags> -Wall –march=atom
Does that sound right?
No, you should have the compiler in the colon seperated segment after the version and the flags last. This is what I use for arm: using gcc : 4.2~arm : # compile-command $(HOME)/cross/arm/bin/arm-g++ : # options <cxxflags>--sysroot=$(HOME)/cross/arm/arm/sys-root <archiver>$(HOME)/cross/arm/bin/arm-ar ; Please remove the spaces in "<cxxflags> -std=c++0x" and add a <cflags>, even better <compileflags> for each option. Or use quotes around them.
Does boost depend on standard precompiled libraries like libstdc++.so?
Yes. This should work. For static libs you should specify the archiver from your cross toolchain as seen above.
I’ve been bit by having the system crash hard in different places, and I suspect that sometimes this is caused by the fact that the host is i686 linux and the target is an atom-based SoC with custom linux libraries. Boost wants to pull them from the host, so I need to tell it everything it should NOT pull silently. Correct?
Most likely. But those normally result in obscure linker errors.
Do I also need a <linkflags> -L/path/to/target/lib/directory?
Should be on the safe side, yes. Please run "b2 -n" first to check if all your flags are on the command and link lines. Yours, Jürgen -- * Dipl.-Math. Jürgen Hunold ! Ingenieurgesellschaft für * voice: ++49 511 262926 57 ! Verkehrs- und Eisenbahnwesen mbH * fax : ++49 511 262926 99 ! Lister Straße 15 * juergen.hunold@ivembh.de ! www.ivembh.de * * Geschäftsführer: ! Sitz des Unternehmens: Hannover * Prof. Dr.-Ing. Thomas Siefer ! Amtsgericht Hannover, HRB 56965 * PD Dr.-Ing. Alfons Radtke ! _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users