Boost logo

Boost :

Subject: Re: [boost] cross-compilation: building boost on linux targetting osx
From: Niklas Angare (li51ckf02_at_[hidden])
Date: 2017-03-01 23:09:48

"Frédéric Bronvia Boost" wrote:
> I am trying to cross-build boost on linux targetting osx.
> I am using a cross compiler based on the linux clang 3.8.1 (osxcross).
> I identified potential issues:
> 1. I give toolset clang to which sets the toolset to
> clang in project-config.jam but clang-linux is used:
> common.mkdir bin.v2/libs/system/build/clang-linux-3.8.1/release
> Should it be clang-darwin instead? builds b2 and the set of toolsets used for this is completely
different than the one Boost.Build has. It needs to be a host native

> Currently, I am using the following commands to build boost:
> and run b2:
> CC="x86_64-apple-darwin13-clang" CFLAGS="-O2 -DNDEBUG"
> CXX="x86_64-apple-darwin13-clang++-libc++" CXXFLAGS="-O2 -DNDEBUG
> -std=c++14"

To my knowledge these environment variables aren't used by Boost.Build.
Aren't they typically used by make, which isn't involved here? Why not put
all the compiler flags in user-config.jam? You can use <linkflags> for the
linker flags. Use quotes like this to reduce repetition:
<cxxflags>"-x -y -z".

> ./b2 -d2

This should make b2 print the full command-line of each command. Have you
compared that to what you expect?

> boost.locale.iconv=on boost.locale.std=off

I have never seen these before. Where are they described?


Niklas Angare

Boost list run by bdawes at, gregod at, cpdaniel at, john at