我正在尝试为xcode 4.6构建 quantlib 。
关注的项目是这个:https ://github.com/philipbarnes/quantlib-on-iOS
这个 quantlib 项目依赖于这个 boost 项目:https ://gitorious.org/boostoniphone/boostoniphone
我的问题是我无法获得这种提升来构建,但我也可以通过 Pete 在 github 上构建另一个版本。
为 iOS 构建 quantlib 的步骤之一要求设置 boost 目录。我试图调整它无济于事。 这意味着我有一个 dir 'boostoniphone-huuskpes-boostoniphone' - 它没有构建,据说是与 iPhone 项目上的 quantlib 一起使用的版本,以及确实构建的 dir 'boostoniphone-master' - 它有一个带有文件夹的不同构建结构,也许在 quantlib 项目中设置 $BOOSTDIR 变量并不是那么简单。
控制台的这些输出已被短路,以便更舒适地阅读
我的gitorious boost 输出说:
3 warnings generated.
darwin.archive bin.v2/libs/thread/build/darwin-6.1~iphonesim/release/architecture-x86/link- static/macosx-version-iphonesim-6.0/target-os-iphone/threading-multi/libboost_thread.a
common.copy stage/lib/libboost_thread.a
...updated 120 targets...
=================================================================
Done
Splitting all existing fat binaries...
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/lipo: can't open input file: /Users/colman/Downloads/boostoniphone-huuskpes- boostoniphone_/src/boost_1_51_0/bin.v2/libs/thread/build/darwin-4.2.1~iphone/release/architecture- arm/link-static/macosx-version-iphone-6.0/target-os-iphone/threading-multi/libboost_thread.a (No such file or directory)
...并继续重复问题,然后此错误是下一个...
ar: obj/*.o: No such file or directory
...armv7s
ar: obj/*.o: No such file or directory
...i386
ar: obj/*.o: No such file or directory
liboficate: thread
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/lipo: can't open input file: /Users/colman/Downloads/boostoniphone-huuskpes- boostoniphone_/src/boost_1_51_0/bin.v2/libs/thread/build/darwin-4.2.1~iphone/release/architecture-arm/link-static/macosx-version-iphone-6.0/target-os-iphone/threading-multi/libboost_thread.a (No such file or directory)
由于另一个 boost 项目对我有用,我尝试将它作为 boost ref 链接到 buildql.sh 脚本中,但我得到:
checking for arm-apple-darwin10-gcc... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple- darwin10-llvm-gcc-4.2
checking whether the C compiler works... no
configure: error: in `/Users/colman/Downloads/boostoniphone-huuskpes-boostoniphone_/QuantLib-1.2.1':
configure: error: C compiler cannot create executables
See `config.log' for more details
和
/Applications/Xcode.app/Contents//Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/lipo: can't open input file: /Users/colman/Downloads/boostoniphone-huuskpes-boostoniphone_/QuantLib-1.2.1/prefix/armv7/lib/libQuantLib.a (No such file or directory)
指向如何制作框架的指针也可能是一种解决方案?但我认为让 quantlib for iOS 项目工作是真正的解决方案。
回到 BOOST 变量,在 buildql.sh 文件中进行了如下更改:
#: ${BOOST_HOME:=$HOME/workspace/huuskpes-boostoniphone}
: ${BOOST_HOME:=$HOME/workspace/boostoniphone-master/}
: ${BOOST_SRC:=$BOOST_HOME/src/boost_1_51_0}
以下内容也进行了更改以尝试适合“boostoniphone-master”
: ${SRCDIR:=`pwd`/src}
: ${BUILDDIR:=`pwd`/build}
: ${PREFIXDIR:=`pwd`/prefix}
: ${FRAMEWORKDIR:=`pwd`/framework}
感谢您的任何提示,潜在的解决方案。