Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-12296

jom can't handle Makefiles when qmake is uses a source directory with spaces (e.g: C:\program files...)

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • Qt Creator 3.3.0-beta1
    • Qt Creator 3.1.0
    • Jom
    • None
    • Windows 7 (x64) Qt5.3 win32-msvc2013 spec
    • 9899d08c1c106e154e7c305b2dc239198b380f45

    Description

      1) set environment variables (to have qmake, relevant libraries and jom)

      set PATH=C:\Qt\5.3\msvc2013_opengl\bin;C:\Qt\Tools\QtCreator\bin;%PATH%

      2) run vcvars32.bat
      call "c:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\vcvars32.bat"

      3) make sure you're on build dir
      cd BUILD_DIR

      4) run qmake using the SOURCE_DIR using proper spec and quotes in the path.
      qmake -r -spec win32-msvc2013 "C:\Program Files (x86)\Jenkins\workspace\testproject\releasetype\release"

      5) build with jom
      jom

      Example of error:

      -DQT_WIDGETS_LIB -DQT_NETWORK_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I"C:\Program Files (x86)\Jenkins\workspace\testproject\releasetype\debug\spec\win32-msvc2013\slippymap" -I"inc" -I"C:\Qt\5.3\msvc2013_opengl\include" -I"C:\Qt\5.3\msvc2013_opengl\include\QtWidgets" -I"C:\Qt\5.3\msvc2013_opengl\include\QtNetwork" -I"C:\Qt\5.3\msvc2013_opengl\include\QtGui" -I"C:\Qt\5.3\msvc2013_opengl\include\QtCore" -I"debug" -I"." -I"C:\Qt\5.3\msvc2013_opengl\mkspecs\win32-msvc2013" -Fodebug\ @C:\Windows\TEMP\testproject.obj.3828.31.jom
      cl : Command line warning D9002 : ignoring unknown option '-std=c++0x'
      cl : Command line warning D9024 : unrecognized source file type 'C:\Program', object file assumed
      cl : Command line warning D9027 : source file 'C:\Program' ignored
      cl : Command line warning D9024 : unrecognized source file type 'Files', object file assumed
      cl : Command line warning D9027 : source file 'Files' ignored

      I worked around it by using a different directory for jenkins (Without spaces) and it worked fine.

      It works fine if you use mingw32-make (with the proper spec of qmake win32-g++, of course) which leads me to believe this is an issue with jom's ability to handle paths with spaces the way mingw32-make does.

      Missing Info:

      nmake works as intended and produces the correct binaries (regardless of the appearance of spaces in the SOURCE_DIR)

      I made a quick test using 2 folders
      SOURCE_DIR_WITHOUT_SPACES:
      "C:\builds\jenkins\lightmaps\win32-msvc2013"
      SOURCE_DIR_WITH_SPACES:
      "C:\builds\jenkins\lightmaps\win32-msvc2013 - copia"

      (copia means copy in spanish)

      Somewhere in the jom processing, it doesn't keep the paths with spaces correctly:

      c1xx : fatal error C1083: Cannot open source file: 'copia\slippymap\lightmaps.cpp': No such file or directory

      Attached files with the output of each combination of jom and nmake with or without spaces.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              jbornema Joerg Bornemann
              alexhans Alex Hans
              Votes:
              2 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes