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

macdeployqt does not copy QtQuickControls2Impl.framework inside the app bundle

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Duplicate
    • Affects Version/s: 6.0.0
    • Fix Version/s: None
    • Labels:
      None
    • Environment:
      macOS v11.1
    • Platform/s:
      macOS

      Description

      I am building an application using Qt/QML with cmake. These are the packages I am using:

      find_package (Qt6 COMPONENTS Core Qml Quick Svg REQUIRED)

      I am generating a DMG installer with macdeploy with the command below

      add_custom_target(pack COMMAND ${CMAKE_PREFIX_PATH}/bin/macdeployqt ${PROJECT_NAME}.app -qmldir=${CMAKE_SOURCE_DIR}/qml -no-strip -dmg)

      After installation the application fails to start with the error below

      QQmlApplicationEngine failed to load component
      qrc:/qml/main.qml:2:1: Cannot load library /Applications/wol.app/Contents/PlugIns/quick/libqtquickcontrols2plugin.dylib: (dlopen(/Applications/wol.app/Contents/PlugIns/quick/libqtquickcontrols2plugin.dylib, 133): Library not loaded: @rpath/QtQuickControls2Impl.framework/Versions/A/QtQuickControls2Impl
      Referenced from: /Applications/wol.app/Contents/PlugIns/quick/libqtquickcontrols2plugin.dylib
      Reason: image not found)

      Manually copying QtQuickControls2Impl.framework in wol.app/Contents/Frameworks before generating the dmg solves this problem

        Attachments

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

          Activity

            People

            Assignee:
            sorvig Morten Sørvig
            Reporter:
            cristeab Bogdan Cristea
            PM Owner:
            Veli-Pekka Heinonen Veli-Pekka Heinonen
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes