January 27, 2012

PopcornKing PopcornKing
Lab Rat
3 posts

Unable to build qt-4.8.0 x86 (32 bit) static on windows xp64 [SOLVED]

 

After downloading qt-everywhere-opensource-src-4.8.0.zip

I unzipped the source in the following directory:

  1. E:\src\qt-everywhere-opensource-src-4.8.0

I then launched visual studio command prompt 2010 (not x64).

  1. E:\build\static_qt-4.8.0-x86> set QTDIR=E:\src\qt-everywhere-opensource-src-4.8.0

  1. E:\build\static_qt-4.8.0-x86> set PATH=%QTDIR%\bin;%PATH%

  1. E:\build\static_qt-4.8.0-x86> set QMAKESPEC=win32-msvc2010

I encountered no errors building a shared version as shown below:

  1. E:\build\shared_qt-4.8.0-x86> ..\..\src\qt-everywhere-opensource-src-4.8.0\configure -debug-and-release -opensource -mp -shared -platform win32-msvc2010
  2. E:\build\shared_qt-4.8.0-x86> nmake

But when I do a similar build for static I get errors:

  1. E:\build\static_qt-4.8.0-x86> ..\..\src\qt-everywhere-opensource-src-4.8.0\configure -debug-and-release -opensource -mp -static -platform win32-msvc2010
  2. E:\build\static_qt-4.8.0-x86> nmake
  3. .
  4. .
  5. .
  6.         mt.exe -nologo -manifest "tmp\obj\debug_static\bearermonitor.intermediate.manifest" -outputresource:debug\bearermonitor.exe;1
  7. NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\bin\mt.exe"' : return code '0x1f'
  8. Stop.
  9. NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN\nmake.exe"' : return code '0x2'
  10. Stop.
  11. NMAKE : fatal error U1077: 'cd' : return code '0x2'
  12. Stop.
  13. NMAKE : fatal error U1077: 'cd' : return code '0x2'
  14. Stop.
  15. NMAKE : fatal error U1077: 'cd' : return code '0x2'
  16. Stop.

I had no problems building both shared and static x64 versions, it is just the static 32 bit giving me errors.
What am I doing wrong?

4 replies

January 28, 2012

koahnig koahnig
Mad Scientist
2101 posts

welcome to devnet

The error seem to be in the example section. So, the libs are probably already compiled and should be fine.

This could be a problem of msvc. If you like to retry, may be do not use -mp option. I have seen strange problems with parallel compilation on Win7 64 bit with msvc 2005. I was required to restart the compilation several times. Eventually it finished and was ok. The sequential compilation was running through ok.

January 28, 2012

PopcornKing PopcornKing
Lab Rat
3 posts

koahnig wrote:

The error seem to be in the example section. So, the libs are probably already compiled and should be fine.

You are right that the libs were already built; this was the most important part so I’m not too worried about the error now. Thanks for your insight!

koahnig wrote:

This could be a problem of msvc. If you like to retry, may be do not use -mp option. I have seen strange problems with parallel compilation on Win7 64 bit with msvc 2005.

I’ll try without the -mp option and if that works then I’ll update the thread title as solved.

January 29, 2012

PopcornKing PopcornKing
Lab Rat
3 posts

Turning off MP didnt work. The configure command seems to ignore -mp or -no-mp switch anyway. I had to change the QMAKE_CFLAGS_MP in E:\build\shared_qt-4.8.0-x86\mkspecs\win32-msvc-2010\qmake.conf

The libraries were at least built before crash as mentioned.

January 29, 2012

koahnig koahnig
Mad Scientist
2101 posts

I have issued a bug report for configure to ignore -mp [bugreports.qt-project.org] .

 
  ‹‹ Qt Build Problem on Mac (g++-4.2: No such file or directory)      [SOLVED] Unable to install QT in Nokia n97 mini ››

You must log in to post a reply. Not a member yet? Register here!