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

Use qt_generate_deploy_qml_app_script MACOS_BUNDLE_POST_BUILD in QML examples

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Reported
    • Priority: P3: Somewhat important
    • Resolution: Unresolved
    • Affects Version/s: 6.3.0
    • Fix Version/s: None
    • Component/s: Build System: CMake
    • Labels:
      None

      Description

      We should use qt_generate_deploy_qml_app_script's MACOS_BUNDLE_POST_BUILD option in our QML examples to simplify their code and ensure that the examples run from inside a macOS app bundle in the build dir.
      We should include a comment above each usage of the option telling why it's needed and shouldn't be removed.

      Here are some examples that currently handle all the bundle-specific magic manually

      https://github.com/qt/qtdeclarative/blob/6e8f6f446ac8854fd23cb3cbf0fc1f3646299ca6/examples/quick/text/CMakeLists.txt#L67
      https://github.com/qt/qtdeclarative/blob/6e8f6f446ac8854fd23cb3cbf0fc1f3646299ca6/examples/quick/shared/CMakeLists.txt#L38
      https://github.com/qt/qtdeclarative/blob/6e8f6f446ac8854fd23cb3cbf0fc1f3646299ca6/examples/quick/shared/QtBundleQmlModuleForMacOS.cmake

      https://github.com/qt/qtdeclarative/blob/6e8f6f446ac8854fd23cb3cbf0fc1f3646299ca6/examples/qml/tutorials/extending-qml/chapter6-plugins/Charts/CMakeLists.txt#L19

      Proposed here
      https://git.qt.io/alcroito/qt6-cmake-api-review/-/blob/master/api_review_qt_6_3_deploy.md#L284

      Split from QTBUG-100925

        Attachments

          Issue Links

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

            Activity

              People

              Assignee:
              qtbuildsystem Qt Build System Team
              Reporter:
              alexandru.croitor Alexandru Croitor
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:

                  Gerrit Reviews

                  There are no open Gerrit changes