标题:如何把qt程序发布到另外一台机器上运行
作者:expressw
日期:2017-02-16 17:50
内容:
我用的是qt5.7.1,在debian上编译运行,现在想制作发布到另外一台机器上ubuntu运行,硬件都是x86的。
根据官网和网上找到的一些指导,把需要的库和plugins都放到目标机器上了,运行的时候报错:
QQmlApplicationEngine failed to load component
qrc:/main.qml:1 module "QtQuick" is not installed
qrc:/main.qml:2 module "QtQuick.Controls" is not installed
qrc:/main.qml:1 module "QtQuick" is not installed
qrc:/main.qml:2 module "QtQuick.Controls" is not installed
网上有说需要安装qt运行库的,把qtdeclarative5-controls-plugin和qtdeclarative5-quicklayouts-plugin的,可是装完之后还是报同样的错误。
#1 [never_forget 02-21 17:00]
QML 打包 cmd 里面去 windeployqtXXX.exe --qmldir C:XXXXXXXX\qml ,楼主是这个意思是不 ?
#2 [reerayxia 02-24 08:37]
静态编译不二选择。。。