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

Qt6QmlMacros doesn't handle build directories with spaces in the path

    XMLWordPrintable

Details

    • macOS
    • c04a69fa7 (6.8.0), 3856e688c (dev), 757681a59 (6.8)

    Description

      Steps to reproduce:

      1. Build a Qt Quick project with a space in the build directory.
      ~/Qt/6.8.0/android_arm64_v8a/bin/qt-cmake -G Ninja -S . -B "build dir"

       

      CMake Error at /Users/ollivuolteenaho/Qt/6.8.0/android_arm64_v8a/lib/cmake/Qt6Qml/Qt6QmlMacros.cmake:1073:EVAL:1 (cmake_language):
        cmake_language DEFER DIRECTORY:    /Users/ollivuolteenaho/Qt/Examples/Qt-6.8.0/quick/text/build  is not known.  It may not have been processed yet.
      Call Stack (most recent call first):
        /Users/ollivuolteenaho/Qt/6.8.0/android_arm64_v8a/lib/cmake/Qt6Qml/Qt6QmlMacros.cmake:1073 (cmake_language)
        /Users/ollivuolteenaho/Qt/6.8.0/android_arm64_v8a/lib/cmake/Qt6Qml/Qt6QmlMacros.cmake:1146 (qt6_add_qml_module)
        /Users/ollivuolteenaho/Qt/Examples/Qt-6.8.0/quick/shared/CMakeLists.txt:15 (qt_add_qml_module)
      -- Configuring incomplete, errors occurred!

       

      The line in question is:

      cmake_language(EVAL CODE "cmake_language(DEFER DIRECTORY ${PROJECT_BINARY_DIR} "

       

      Adding \"\" around ${PROJECT_BINARY_DIR} would seem to fix it, but probably best for someone else to check.

      Regression from 6.7.3. Haven't tried on Windows/Linux.

      Attachments

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

        Activity

          People

            semlanik Alexey Edelev
            olvuolte Olli Vuolteenaho
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes