Static build in Qt on Windows Vista

I am currently running Windows Vista Home Premium, and I developed the application with my friend using Qt Creator. Now we are trying to deploy our application as a single executable file, so we are trying to make a static assembly. We added CONFIG + = static to our .pro file.

We use this documentation to help us:

http://doc.trolltech.com/4.1/deployment-windows.html 

When I try to build QT, I use this command:

 configure -static -platform win32-msvc 

Then I get this error:

 Creating qmake... execute: File or path is not found (nmake) execute: File or path is not found (nmake) Cleaning qmake failed, return code -1 

I think I should add nmake to my PATH, but I cannot find it on my computer. Any help would be greatly appreciated. Thanks.

+1
source share
2 answers

You will find the batch file in the bin directory of your visual studio installation called "vcvars32.bat". Run this from the command line before trying to create QT. This should solve your problems.

+3
source

Open the Visual Studo 20xx Command Prompt and compile Qt inside it.

For example, on VS2008, I also need to install QMAKESPEC before trying to configure Qt:

 set QMAKESPEC=<QT_DIR>\mkspecs\win32-msvc2008 
+1
source

Source: https://habr.com/ru/post/954338/


All Articles