如何使用 Boost uBLAS C++ iPhone 项目中的库?
我想在我的 iPhone 项目中使用 Boost 库,特别是 boost::numeric::ublas。我设法构建了用于 boost 的静态库,以便将它们链接到我的 iPhone 项目中。然而,当我查看这些 .a 库时,我找不到与 ublas 相关的库(我在终端中尝试了 ./bootstrap.sh --with-libraries=ublas 但没有运气)。有谁知道要查找 ublas 哪个静态库?或者一般如何在 iPhone 项目中使用 ublas?
谢谢!
I want to use Boost library in my iPhone project, specifically only boost::numeric::ublas. I managed to build static libraries for boost in order to link them in my iPhone project. However, when I look at those .a libraries I can't find one that's related to ublas (I tried ./bootstrap.sh --with-libraries=ublas in terminal but no luck). Does anyone know which static library to look for ublas? Or how to use ublas in an iPhone project in general?
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
uBlas 仅包含标头,因此没有静态库 - 请参阅以下库视图:
http://www.boost.org/doc/libs/1_44_0/?view=filtered_header-only
uBlas is header-only so there is no static library - see this view of the libraries:
http://www.boost.org/doc/libs/1_44_0/?view=filtered_header-only
如果您可以只运行 iOS4,请使用 Accelerate 框架,它具有 BLAS 并具有硬件加速功能(如果可用,则使用软件加速)。
即使您需要 3.x 支持,也值得弄清楚如何在可能的情况下切换 Accelerate 的使用以获得硬件支持。
If you are OK with running iOS4 only, use the Accelerate framework, it has BLAS and features hardware acceleration (when available, software otherwise).
Even if you need 3.x support, it would be worth figuring out how to toggle the use of Accelerate when possible just to get the hardware support.
我无法回答 iPhone 特定的部分,但我至少可以在 Boost 部分提供帮助...
Boost uBlas 是一个仅包含头文件的库,因此您不需要构建和链接任何 .a 文件。如果您想使用该库,只需在项目中包含标头即可。
I can't answer the iPhone-specific part but I can help at least with the Boost part...
Boost uBlas is a header-only library so you don't need to build and link against any .a files. Just include the headers in your project if you want to use the library.