使用Boost库时出错
Errors in using Boost library
//上次错误消失时编辑
我已经将ppclinux库替换为特定的库。新错误显示为-
libboost_thread-gcc44-mt-1_49.a(thread.o): relocation R_X86_64_32 against `.text' can not be used when making a shared object; recompile with -fPIC
../../ThirdPartyLibs/boost/stage/lib/libboost_thread-gcc44-mt-1_49.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [libAFE.so] Error 1
有什么解决方案吗?
解决了它。
问题是这些库是用64位构建的。配置bjam命令解决了这个问题。命令如下-
bjam toolset=gcc address-model=64 architecture=x86 variant=release link=static,shared --layout=versioned --build-type=complete
相关文章:
- 在成员dynamic_bitset上使用 boost::from_block_range 时出错,但在本地dynamic
- 执行时使用 boost::asio::d eadline_timer 时出错
- 使用boost库(cpp_int)时获取常量时出错
- 断开连接后重新连接boost beast(asio)websocket和http连接时出错
- 将 boost 与 Visual Studio 和 vcpkg 链接时出错
- Boost FFT示例-编译时出错,这段代码在做什么
- Python 3.6 的 boost 和 dlib 安装期间出错
- 在 boost::heap::p riority_queue 中推送结构对象时出错
- 编译在 Python 代码内部调用的 C++ 代码时出错,使用 Boost Python
- 使用 boost::bind 进行订阅回调时出错
- 将 std::bind 应用于带有参数 <boost::asio::ip::tcp::socket> 时出错?
- ctime 包含 boost::文件系统时出错
- 构建 boost 1.61 iostream 时出错 - 使用 -fPIC 重新编译
- 将 CLANG 构建的可执行文件与 G++-v6 构建的 Boost 库链接时出错
- 导入 Boost Python 模块 (function_impl_base9max_arityEv) 时出错
- 使用由 Mingw 5.3 编译的 boost ASIO 库使用 QT 时出错
- Boost Python:在函数中通过引用传递变量时出错
- 编译用于创建boost.log格式的代码时出错
- 在 Cygwin 64 上包含 boost.asio 时出错
- 浮点数学出错使用来自 boost::multiprecision 的cpp_bin_float