c++ - 添加符号时出错 : DSO missing from command line

标签 c++ qt ogre

尝试在Qt项目中使用Ogre。 Ogre 构建成功。运行项目它给我三个错误:

/usr/lib/x86_64-linux-gnu/libboost_system.so.1.54.0:-1: error: error adding symbols: DSO missing from command line
-1: error: main.o: undefined reference to symbol '_ZN5boost6system15system_categoryEv'

当我搜索错误时,它说要编辑 makefile 并添加: LIBS =-lp线程

但它已经存在了。

如何解决这个错误?

最佳答案

您需要在项目中链接 boost 库。

在项目的 pro 文件中添加 LIBS += -lboost_system

关于c++ - 添加符号时出错 : DSO missing from command line,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25864797/

相关文章:

c++ - 为什么 Win32 mutex 这么耗时

c++ - CMake的find_library()显然没有找到库

mesh - 如何使用 OGRE 创建 .mesh 文件?

qt - QDir 和 QDirIterator 忽略具有非 ASCII 文件名的文件

css - 为什么我的 QWidget 样式表无法识别 objectName 规则?

c++ - 如何知道当前正在移动哪个 QGraphicsItem?

c++ - 将 ogre3d 与全息透镜集成

android - OpenCV undefined reference `cv::fastFree(void*)'

c++ - 实现通用 map [来自 HW]

c++ - 函数调用中的 std::array 隐式初始化