How Windows packages QT Programs

Source: Internet
Author: User

Many QT enthusiasts want to release their QT software, but find that they do not work on other machines that do not have the QT SDK installed, which is what this article wants to illustrate. Now most of the online software to publish their own development of the application, will be packaged into EXE files, to install the EXE file, will generate a lot of small files, in fact, the same principle, just the use of their own packaging tools can not. This article mainly describes how the Windows platform to package their own QT program, relatively simple, there is no formal software wizard process.

In the Windows system, to package the QT program, the main use of 3 kits, respectively:

1.hap-depends viewing the software's dependent libraries (*.dll)

2. Aspack dynamic link library compression software

Packaging tools for 2.filepack software

These three are available on the Internet and I am here to provide:

Hap-depends + aspack+ Filepack

This article takes the "CSDN blog downloader" Software as an example, here are the detailed steps for some of the packaging procedures:

1. Open the QT application using the Hap-depends tool

2. After opening, you can see a lot of warnings, those warning (yellow question mark) corresponding to the library is the required dynamic link library, to the QT installation directory copy to the directory where the application.

3. To the Qt installation directory, Xx/qt/4.8.0/bin, you can see a lot of *.dll files

4. These are QT's dynamic link libraries

5. Copy the DLL file of the warning to the QT program directory

6. The interface can be opened at this time, but also can be used, but in other computers is not normal, because the program used in the picture library, database driver, and play the video library, need to use these plugins .

7.Qt Plugins Plug-in

8. Copy the plugin to the directory of the program, the original in the Plugins sqldrivers directory, copy to here also folder name must be consistent.

9. The program starts, copy to other computer also can run normally.

10. This is in the compressed DLL file, most of it is possible, but some will fail, so at the time of release, it must be tested on multiple computers, from which we can see that the original file has changed to the end of. bak, the size difference is quite large. Of course, this one is not necessary, because the following packaging tools can compress the file.

11. Start Packing QT Programs

12. This tool is very simple, the next step is OK, then select the directory for the program.

13. Select the executable file you want to package.

14. Settings

15. Variable list: Refers to the package after the program is opened, the files extracted to where, this can choose different variables to see the results, the general program is placed in the temporary directory, so choose "*tempdir*". The output directory of the executable file can be easily copied out after packing.

16.

17. Create

18. Package Success

19. After the package, the program has 8.03MB, if too large, packaging, or every execution will be re-decompression, affecting the speed.

There are other more advanced, more complex program packaging tools, those tools and so on later to use to explore. The above several kits do not need points, you can download unlimited.

How Windows packages QT Programs

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.