Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-15317

Creating Xcode project from .pro file using qmake will not quote certain strings in Xcode project, causing build errors.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: P2: Important P2: Important
    • 5.0.0 Beta 2
    • 4.7.0
    • Build tools: qmake
    • None
    • Mac OSX 10.6.4 (64 bit), Xcode 3.2.4 (64 bit), QT 4.7.0 (64 bit, revision b06f25f265)
    • 55b63a406fced6c4db0e18a7170932de1c6a5c21

      Using qmake to build an Xcode project file from a QT project file doesn't quote some file paths in the Xcode project.pbxproj file, causing build errors in Xcode if the path to the file has spaces in it (e.g. "/Users/user/Documents/QT Projects/test").

      Steps to reproduce:
      1. Create a new QT project.
      2. Use qmake to create an Xcode project file.
      3. Open the project in Xcode and try to compile.

      The following errors are produced:
      Make: test.xcodeproj/qt_makeqmake.mak: No such file or directory
      Make: test.xcodeproj/qt_preprocess.mak: No such file or directory

      Workaround:
      1. Locate the xcodeproj file created from the qmake process.
      2. Show its contents (Show Package Contents).
      3. Open project.pxproj in a text editor.
      4. Search for "qt_preprocess.mak" and "qt_makeqmake.mak".

      Something like the following lines should be found:

      shellScript = "make -C /Users/user/Documents/QT Projects/test -f 'test.xcodeproj/qt_preprocess.mak'";

      shellScript = "make -C /Users/user/Documents/QT Projects/test -f 'test.xcodeproj/qt_makeqmake.mak'";

      Add quotes around the paths so that they become '/Users/user/Documents/Qt Projects/test'.

      5. The project should now compile.

        For Gerrit Dashboard: QTBUG-15317
        # Subject Branch Project Status CR V

            andysh Andy Shaw
            chrisparton1991 Chris Parton
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes