Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Weird mac .app build (was fine in December)
QtWS25 Last Chance

Weird mac .app build (was fine in December)

Scheduled Pinned Locked Moved Solved Installation and Deployment
mac osdeploymentcodesign
6 Posts 2 Posters 857 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    artwaw
    wrote on 4 Mar 2021, 12:26 last edited by
    #1

    I noticed something odd in a way resulting .app is being build. Can't exactly say when did this happened since I don't codesign too often...

    So, my last deployment was in December and it went as usual: macdeployqt, codesign app, create dmg, codesign dmg, send it over.
    Yesterday I tried to do same but codesign failed repeatedly with peculiar message about root being not sealed in .app file.
    I took a peek inside. Somehow, apart from Content folder that I would expect to be there, there was whole .app file again, so I had:
    In myprogram.app:

    • Content
    • myprogram.app

    Folder myprogram.app had the expected content. In order to codesign and ship I had to manually remove myprogram.app and its subfolders from myprogram.app root.

    Any ideas what had happened here? This is reproducible issue.

    For more information please re-read.

    Kind Regards,
    Artur

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 4 Mar 2021, 19:49 last edited by
      #2

      Hi,

      Did you change anything in between ?
      Xcode version ?
      Qt Creator ?
      Project parameters ?
      Build output configuration ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      A 1 Reply Last reply 4 Mar 2021, 20:58
      0
      • S SGaist
        4 Mar 2021, 19:49

        Hi,

        Did you change anything in between ?
        Xcode version ?
        Qt Creator ?
        Project parameters ?
        Build output configuration ?

        A Offline
        A Offline
        artwaw
        wrote on 4 Mar 2021, 20:58 last edited by
        #3

        @SGaist usual update of QtCreator (I tend to keep it up to date despite introducing new bugs in clang-lazy) and xcode. Nothing else changed, I had a brief update to Qt6 but then rolled back to 5.15.2.
        Precisely:

        • it worked in the first days of December on 5.15.2
        • it worked in the first days of December on 6
        • then fast forward to yesterday when I discovered the issue.

        In the meantime there was update of QtCreator and xcode.

        For more information please re-read.

        Kind Regards,
        Artur

        1 Reply Last reply
        0
        • S Offline
          S Offline
          SGaist
          Lifetime Qt Champion
          wrote on 4 Mar 2021, 21:16 last edited by
          #4

          Anything strange in the project setting ?
          Do you have the same issue if you build your project on the command line ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          A 1 Reply Last reply 4 Mar 2021, 21:20
          0
          • S SGaist
            4 Mar 2021, 21:16

            Anything strange in the project setting ?
            Do you have the same issue if you build your project on the command line ?

            A Offline
            A Offline
            artwaw
            wrote on 4 Mar 2021, 21:20 last edited by
            #5

            @SGaist No, nothing strange. It is really simple (and I never touch default settings set by the installer). Pro file:

            QT       += core gui svg printsupport
            
            greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
            
            CONFIG += c++17
            CONFIG += sdk_no_version_check
            
            SOURCES += \
                aboutdialog.cpp \
                main.cpp \
                prefsdialog.cpp \
                qgraphicsmovieitem.cpp \
                viewer.cpp
            
            HEADERS += \
                aboutdialog.h \
                prefsdialog.h \
                qgraphicsmovieitem.h \
                viewer.h
            
            FORMS += \
                aboutdialog.ui \
                prefsdialog.ui \
                viewer.ui
            
            TRANSLATIONS += \
                TNImageViewer_en_GB.ts \
                TNImageViewer_pl_PL.ts
            
            RESOURCES += \
                res.qrc
            
            DISTFILES += \
                TNImageViewer_en_GB.qm \
                TNImageViewer_pl_PL.qm
            
            macx: {
            QTPLUGIN += libcocoa\
                    libcocoaprintersupport\
                    libqmacstyle
            
            ICON = img/iconTNIV.icns
            
            QMAKE_TARGET_BUNDLE_PREFIX = my.domain.here
            QMAKE_BUNDLE = TNImageViewer
            }
            
            win32: {
            QTPLUGIN += qwindows\
                    windowsprintersupport
            
            RC_ICONS += img/TNImageViewer.ico
            }
            
            

            Truth to tell I never build any project using command line. Creator always worked...

            For more information please re-read.

            Kind Regards,
            Artur

            1 Reply Last reply
            0
            • A Offline
              A Offline
              artwaw
              wrote on 4 Mar 2021, 21:36 last edited by
              #6

              After the advice from @SGaist I started to experiment a bit with settings of the build steps: problem disappeared after I did these three steps one by one (after each I checked if the problem is gone - it disappeared after the last step:

              • turning off QML debugging and profiling switch (default was "leave default", effective call showed CONFIG+=qml_debug now it is CONFIG-=)
              • turning off QtQuick compiler (default was "leave default, effective call showed CONFIG+=qtquickcompiler now it is CONFIG-=)
              • deleting shadow build folders (I do it routinely once a week or so anyway).

              Now the problem is gone, I am marking the topic as "solved".

              For more information please re-read.

              Kind Regards,
              Artur

              1 Reply Last reply
              0

              1/6

              4 Mar 2021, 12:26

              • Login

              • Login or register to search.
              1 out of 6
              • First post
                1/6
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved