Boost logo

Boost Users :

Subject: Re: [Boost-users] [cross-compiling]
From: Wilde, Donald S (donald.s.wilde_at_[hidden])
Date: 2011-07-26 14:11:28


Thanks so much, Jürgen!!!

-----Original Message-----
From: boost-users-bounces_at_[hidden] [mailto:boost-users-bounces_at_[hidden]] On Behalf Of Jürgen Hunold
Sent: Tuesday, July 26, 2011 10:47 AM
To: boost-users_at_[hidden]
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_at_[hidden] ! 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_at_[hidden]
http://lists.boost.org/mailman/listinfo.cgi/boost-users


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net