Boost logo

Boost Users :

Subject: Re: [Boost-users] Error building the libraries for iPhone
From: Harald Maassen (coamithra_at_[hidden])
Date: 2009-03-26 05:38:02


Would it be considered bad form to bump this? ;)

I'm still quite stuck with this problem and can't run these great
libraries on the iPhone..

>>
Hello,

I've recently added the Boost header libraries to my iPhone project,
but I'd also like to use some of the compiled libraries. I've looked
at the documentation and archives for the correct procedure, but I'm
hitting a snag.
I have added the following to the user-config.jam file:

using darwin : 4.0.1~iphone
   :
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/g++
-arch arm
   : <striper>
   : <architecture>arm <target-os>iphone <macosx-version>iphone-2.0
   ;
using darwin : 4.0.1~iphonesim
   :
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++
   : <striper>
   : <architecture>x86 <target-os>iphone <macosx-version>iphonesim-2.0
   ;

I then run bjam with the following parameters:

bjam toolset=darwin architecture=arm target-os=iphone
macosx-version=iphone-2.0 define=_LITTLE_ENDIAN

Which fails on linking with the following message:

darwin.link.dll
bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/libboost_math_c99-xgcc40-mt-1_38.so.1.38.0
lipo: /var/folders/1D/1DnUneWfGcCdxmoK6T0p2U+++TI/-Tmp-//ccpVFzN4.out
and /var/folders/1D/1DnUneWfGcCdxmoK6T0p2U+++TI/-Tmp-//cciyh1K6.out
have the same architectures (armv6) and can't be in the same fat
output file
    "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/g++"
"-arch" "arm" -dynamiclib -Wl,-single_module -install_name
"libboost_math_c99-xgcc40-mt-1_38.so.1.38.0" -o
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/libboost_math_c99-xgcc40-mt-1_38.so.1.38.0"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/acosh.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/asinh.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/atanh.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/cbrt.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/copysign.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/erfc.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/erf.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/expm1.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/fmax.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/fmin.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/fpclassify.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/hypot.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/lgamma.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/llround.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/log1p.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/lround.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/nextafter.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/nexttoward.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/round.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/tgamma.o"
"bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/trunc.o"
     -headerpad_max_install_names -Wl,-x -Wl,-dead_strip
-no_dead_strip_inits_and_terms -isysroot
/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS2.0.sdk
-arch armv6
...failed darwin.link.dll
bin.v2/libs/math/build/darwin-4.0.1~iphone/release/architecture-arm/macosx-version-iphone-2.0/target-os-iphone/threading-multi/libboost_math_c99-xgcc40-mt-1_38.so.1.38.0...

Any insights on what I'm doing wrong here?
<<


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