【发布时间】:2009-07-11 14:54:07
【问题描述】:
经过大量黑客攻击后,我设法为 iphone 编译了设备和模拟器的 boost-libraries,但是当我尝试使用它们时,我在 xcode 调试器中收到错误消息:
dyld: Library not loaded: libboost_graph.so.1.40.0
我猜这是 iphone 上不允许的动态库加载器。我将应用程序与-Lboost_graph 链接为编译器标志。
这是我用于构建 boost 的脚本:
./bjam $1 $2 $3 \
toolset=darwin \
architecture=arm \
target-os=iphone \
macosx-version=iphone-3.0 \
define=_LITTLE_ENDIAN \
--layout=system \
--libdir=/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.0.sdk/usr/lib \
--includedir=/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.0.sdk/usr/include \
link=static \
runtime-link=static
./bjam $1 $2 $3 \
toolset=darwin \
architecture=x86 \
target-os=iphone \
macosx-version=iphonesim-3.0 \
--layout=system \
--libdir=/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator3.0.sdk/usr/lib \
--includedir=/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator3.0.sdk/usr/include \
link=static \
runtime-link=static
我猜我在这里遗漏了一些非常基本的东西,但是什么?
是为动态加载而编译的库(平台/usr/lib中既有.a文件也有.so文件)
【问题讨论】:
-
您找到解决此问题的方法了吗?