c++ - VlcQt 中对函数的未定义引用(安装后)
问题描述
我最近为 ubuntu 16.04 安装了 VlcQt 库,但是当我尝试使用它时,我得到的只是undefined reference to 'some_function()'
.
目前我正在尝试将视频播放器暴露给 QML。
主文件
#include <QGuiApplication>
#include <VLCQtCore/Common.h>
#include <VLCQtQml/QmlVideoPlayer.h>
#include "Controller.h"
int main(int argc, char *argv[])
{
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
QGuiApplication app(argc, argv);
VlcCommon::setPluginPath(app.applicationDirPath() + "plugins");
VlcQmlVideoPlayer::registerPlugin();
Controller controller;
QQuickWindow *quickWindow = qobject_cast<QQuickWindow *>(controller.view());
quickWindow->show();
return app.exec();
}
当我尝试包含库时,Qt intellisense 正在检测该库是否存在。
我究竟做错了什么?
谢谢您的帮助!
//编辑:
我通过他们的存储库安装了它:
add-apt-repository ppa:ntadej/tano
apt-get install libvlc-qt-core2 libvlc-qt-widgets2 libvlc-qt-dbg libvlc-qt-dev
//编辑:这就是我在 .pro 文件中添加库的方式,也已经尝试INCLUDEPATH
过了
LIBS += -lvlccore -lvlc
解决方案
推荐阅读
- curve-fitting - 用于 msc ADAMS 软件中强加运动的样条拟合
- snowflake-cloud-data-platform - 对不同值求和
- c++ - CMakeLists.txt:251 处的 CMake 错误(消息):无法确定正则表达式后端的源文件
- node.js - Nestjs wss handleConnection(socket) socket.handshake 未定义,无法访问标头进行身份验证
- c# - Microsoft Graph 获取所有用户异常不受支持的查询
- javascript - 我的第一个计算器的问题(JavaScript(没有 html,css)
- amazon-web-services - AWS Lambda destination Lambda not triggering
- c# - 无法覆盖 Equals 时如何比较两个对象?
- typescript - 使用 cypress,测量页面加载时间
- javascript - 如何将单词与字符串的一部分进行比较