是否可以在没有从源代码构建Qt的情况下部署Qt应用程序? [英] Is it possible to deploy a Qt application without Qt built from source?

查看:87
本文介绍了是否可以在没有从源代码构建Qt的情况下部署Qt应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在带有Raspbian Jessie的Raspberry Pi 2上使用Qt Creator用C ++编写了一个应用程序。现在,我想部署它,以便可以在功能最少的另一个Raspberry上使用它。这意味着没有安装Desktop-gui或qtcreator。我在那上面使用Raspbian Jessie Lite。

I wrote an application in C++ using the Qt Creator on a Raspberry Pi 2 with Raspbian Jessie. Now I want to deploy it so I can use it on another Raspberry that has minimal functionality. That means there is no desktop-gui or qtcreator installed. I am using Raspbian Jessie Lite on that one.

我试图遵循本文档,但静态链接或共享库方法均无效。
http://doc.qt.io/qt-5/ linux-deployment.html

I tried to follow this Documentation, but neither the static linking nor shared libraries approach works. http://doc.qt.io/qt-5/linux-deployment.html

在彻底搜索之后,这似乎不起作用,因为我安装了Qtcreator而不是从源代码构建 。
这个假设对吗?

After searchin around thoroughly it seems like this doesn't work because I have Qtcreator is "installed" instead of "built from Source". Is that assumption right?

在没有源代码构建的情况下是否无法部署我的应用程序?

Is it not possible to deploy my application without the build from source?

推荐答案

因此,基本上,您希望将Qt应用程序部署在未安装Qt的其他系统中。

So, basically you want to deploy your Qt application in some other system where Qt is not installed.

Qt部署在linux中是一个相当困难的过程。您共享的链接是一个知识渊博但困难的部署过程。

Qt deployment in linux is quite a difficult process. The link that you shared is quite a knowledgeable but difficult process of deploying.

为了使其更加简单,我建议您看一下。在这里您可以找到可执行二进制文件,您可以使用该文件创建独立的 appimage 可以在任何其他系统(运行相同发行版的Linux)中运行。您只需输入Qt Creator本身创建的可执行二进制文件的路径,上述工具即可完成其余工作。它将解决所有依赖性并输出Qt应用程序的独立二进制文件,该文件可以在其他系统中运行。

To make it a lot simpler, I would suggest to take a look into this. Here you can find an executable binary, using which you can create a standalone appimage of you Qt project which can be run in any other system (which running the same distribution of linux). You have to just input the path of the executable binary created by Qt Creator itself, the above said tool will do the rest. It will resolve all dependency and output a standalone binary of your Qt application, that can be run in other systems.

我愿意接受其他问题。希望这可以帮助。

I am open to further questions. Hope this helps.

这篇关于是否可以在没有从源代码构建Qt的情况下部署Qt应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆