Fatal error compiling Qt on Windows

I tried to build Qt 5.0.1 with MSVS2010 on Windows 7.

These are my steps:

  • Extract source code in C: \ Qt \ 5.0.1
  • Run command line VS2010
  • Set the type (this step took approximately 45 minutes)
  • Type nmake

After an hour, I get the following error:

"C:\Program Files (x86)\Microsoft DirectX SDKUtilities\bin\x86\fxc.exe" /nologo /E standardvs /T vs_2_0 /Fh shaders\standardvs.h ..\..\..\3rdparty\angle \src\libGLESv2\shaders\Blit.vs 'C:\Program' is not recognized as an internal or external command, operable program or batch file. NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft DirectX SDKUtiliti es\bin\x86\fxc.exe' : return code '0x1' Stop. NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 10.0 \VC\bin\nmake.exe"' : return code '0x2' Stop. NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop. NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop. NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop. NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop. NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop. 

I searched the Internet and saw many solutions, but none of them solved my problem. I even reinstalled Windows and repeated these steps, but again got the same error.

+2
source share
1 answer

You have spaces and brackets in your env paths. Try using a shortcut, you can get them by opening a Windows command prompt with cmd and type dir /X Short names will appear before the corresponding directories.

for example, if you have a script to configure your environment:

 SET VISUALDIR=C:\Program Files\Microsoft Visual Studio 9.0 SET PATH=%VISUALDIR%\VC\bin;%PATH% 

becomes

 SET VISUALDIR=C:\PROGRA~1\MICROS~1.0 SET PATH=%VISUALDIR%\VC\bin;%PATH% 

If you do not have a script, the erroneous path may be set in the Windows PATH environment variable by default. Then you have to manually modify the PATH variable and apply shortcuts here.

window power

+5
source

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


All Articles