Qt5在Windows上部署 [英] Qt5 Deployment on Windows

查看:316
本文介绍了Qt5在Windows上部署的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在审查如何将我的桌面应用程序从Qt5 Creator部署到一组.dll和一个.exe。所记录的过程看起来很可笑: http:// qt-project .org / doc / qt-5.0 / qtdoc / deployment-windows.html

请帮助我更好地理解。

I have been reviewing how to deploy my desktop application from Qt5 Creator to a set of .dll's and an .exe. The process as documented seems ridiculously complex: http://qt-project.org/doc/qt-5.0/qtdoc/deployment-windows.html.
Please can you help me understand it better.

只是复制.dlls找到使用Dependency Walker不工作-t告诉我有一个缺少的入口点Qt5Core.dll,我已经尝试过每个单一版本的Qt5Core.dll在我的硬盘上。但我离题。

Just copying the .dlls found using the Dependency Walker does not work -t tells me there is a missing entry point for Qt5Core.dll, and I have tried every single version of Qt5Core.dll on my hard drive. But I digress.


  1. 它说你必须静态构建QT。


  2. 一旦我建立了静态,我如何撤消这个操作并回到正常的环境? 。

  3. 有没有我可以运行的工具,它为我做了什么?

  1. It says you have to build QT statically. What does this actually do?
  2. Once I have built statically, how do I undo this and get back to my normal environment?
  3. Step 1 says . Where do I find out where these options are?
  4. Is there a tool I can just run which does this for me?

非常感谢。

(我正在使用Windows 7和Qt 5.1。)

(I'm using Windows 7 and Qt 5.1.)

推荐答案

我必须包含所有这些Qt dll与我的应用程序?

静态链接是罕见的。您可能正在使用LGPL许可,因此您应该动态链接。

Statically linking is rare. You are probably using LGPL licensing, so you should dynamically link.

在链接中提到的页面底部,它提供了一个示例项目的dll依赖。 p>

Towards the bottom of the page you mentioned in your link, it gives an example project's dll dependencies.


当查看Plug&使用depends工具绘制可执行文件(plugandpaint.exe),该工具列出了以下对非系统库的直接依赖性:

When looking at the release build of the Plug & Paint executable (plugandpaint.exe) with the depends tool, the tool lists the following immediate dependencies to non-system libraries:

它给出了一堆dll的图表。根据.pro文件中的模块,您将需要不同的dll和不同的运行时编译器依赖。

And then it gives the chart of a bunch of dll's. Depending on the modules in your .pro file you will need different dll's and different runtime compiler dependencies.

希望有帮助。

这篇关于Qt5在Windows上部署的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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