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

Add App.app/Contents/PlugIns/qml as a default qml import path for macOS apps

    XMLWordPrintable

Details

    • macOS

    Description

      This would relieve the project developer from changing their C++ code to add a import path manually, as well as introduce a common way of doing it for all macOS apps.
      Potentially this simplifies default bundling / deployment qml logic.

      There is currently one qtdeclarative example that does that manually.
      https://github.com/qt/qtdeclarative/blob/dev/examples/qml/tutorials/extending-qml/chapter6-plugins/main.cpp#L60

      The discussion popped up before at
      https://codereview.qt-project.org/c/qt/qtdeclarative/+/366961/1/examples/qml/tutorials/extending-qml/chapter6-plugins/Charts/CMakeLists.txt#23
      and
      https://codereview.qt-project.org/c/qt/qtdeclarative/+/366961/5/examples/qml/tutorials/extending-qml/chapter6-plugins/Charts/CMakeLists.txt#22

      A few other examples currently set 'PlugIns', not 'PlugIns/qml' as an import path manually.
      https://github.com/qt/qtdeclarative/blob/dev/examples/quick/shared/shared.h#L58
      https://github.com/qt/qtdeclarative/blob/dev/examples/quick/shared/QtBundleQmlModuleForMacOS.cmake#L15

      Attachments

        Issue Links

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

          Activity

            People

              qtqmlteam Qt Qml Team User
              alexandru.croitor Alexandru Croitor
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes