Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt Frameworks issues with MacOS notarization
QtWS25 Last Chance

Qt Frameworks issues with MacOS notarization

Scheduled Pinned Locked Moved Solved General and Desktop
macosframework
15 Posts 5 Posters 2.8k 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.
  • S Offline
    S Offline
    SGaist
    Lifetime Qt Champion
    wrote on 31 Jan 2020, 22:06 last edited by
    #6

    macdeployqt uses macOS tools to gather the required information. What was the missing framework ?

    Recent version of the tool got fixed with regard to some missing framework or plugins.

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

    P 1 Reply Last reply 1 Feb 2020, 11:13
    1
    • S SGaist
      31 Jan 2020, 22:06

      macdeployqt uses macOS tools to gather the required information. What was the missing framework ?

      Recent version of the tool got fixed with regard to some missing framework or plugins.

      P Offline
      P Offline
      p_Each
      wrote on 1 Feb 2020, 11:13 last edited by
      #7

      @SGaist QtOpenGL. It caused the macdeployqt command to fail during the signing process, so I tried to add it manually (using cp -R command) and to re-sign the bundle calling codesign but it gave the "unsealed contents" error again.
      This is why I asked if there is a way to specify manually the frameworks to be added by macdeployqt or a way to figure out why it is not adding it

      1 Reply Last reply
      0
      • S Offline
        S Offline
        SGaist
        Lifetime Qt Champion
        wrote on 1 Feb 2020, 21:34 last edited by
        #8

        Can you check with the windeployqt version coming with the latest Qt 5.14 ?
        Note that Qt 5.12.7 has been released, you might also want to upgrade.

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

        P A 2 Replies Last reply 3 Feb 2020, 13:02
        1
        • S SGaist
          1 Feb 2020, 21:34

          Can you check with the windeployqt version coming with the latest Qt 5.14 ?
          Note that Qt 5.12.7 has been released, you might also want to upgrade.

          P Offline
          P Offline
          p_Each
          wrote on 3 Feb 2020, 13:02 last edited by
          #9

          @SGaist I just tried with Qt 5.14.1 and this time macdeployqt was successful. There are still some notarization issues with the hardened runtime and some default entitlements I granted to the app but at least the frameworks look in place now. Thank you for your help

          1 Reply Last reply
          0
          • S Offline
            S Offline
            sierdzio
            Moderators
            wrote on 3 Feb 2020, 13:12 last edited by
            #10

            Not sure if it will help in anything, but I used this script on a .dmg and it works well (although not reliably - Apple randomly rejects notarization calls, but it's usually to wait a bit and run it again).

            (Z(:^

            P 1 Reply Last reply 3 Feb 2020, 13:47
            2
            • S sierdzio
              3 Feb 2020, 13:12

              Not sure if it will help in anything, but I used this script on a .dmg and it works well (although not reliably - Apple randomly rejects notarization calls, but it's usually to wait a bit and run it again).

              P Offline
              P Offline
              p_Each
              wrote on 3 Feb 2020, 13:47 last edited by
              #11

              @sierdzio thanks. My notarizations issues after switching to the latest Qt version were easier to solve fortunately, I only had forgotten to enable the Hardened Runtime and to put a timestamp when signing the bundle

              1 Reply Last reply
              0
              • S SGaist
                1 Feb 2020, 21:34

                Can you check with the windeployqt version coming with the latest Qt 5.14 ?
                Note that Qt 5.12.7 has been released, you might also want to upgrade.

                A Offline
                A Offline
                angadhanoa
                wrote on 24 Mar 2020, 01:54 last edited by angadhanoa
                #12

                @SGaist and @p_Each, i am facing the same problem. I have tried this in 5.12.4 and 5.14.1. The entire application gets code signed but notarization and sptcl fails because of "unsealed contents present in the root directory of an embedded framework". Spctl specifically mentions unsealed contents and when i try "codesign --verify --verbose=4 --deep" on any Qt framework. I have also tried verifying every component of the framework using the codesign command in the framework but it states that they are valid on disk and satisfies its Designated Requirement. The only file which has no code-signature in the framework is the CodeResources file created by the codesign itself and placed in the _CodeSignature folder.

                I have created the following symbolic links:

                QtGui.framework
                |_ QtGui -> Versions/Current/QtGui
                |_ Resources -> Versions/Current/Resources
                   |_ Info.plist
                |_ Versions
                   |_ 5
                      |_ QtGui
                      |_ Resources
                      |_ _CodeSignature
                         |_ CodeResources
                    |_ A -> 5 
                    |_ Current -> 5
                

                Codesign command:

                "codesign --force --verify --verbose --entitlements 'abc.plist' --sign 'Developer ID Application: ABC (XYZ)' --timestamp --options=runtime --strict QtGui.framework/Versions/5 "
                
                S 1 Reply Last reply 24 Mar 2020, 19:40
                0
                • A angadhanoa
                  24 Mar 2020, 01:54

                  @SGaist and @p_Each, i am facing the same problem. I have tried this in 5.12.4 and 5.14.1. The entire application gets code signed but notarization and sptcl fails because of "unsealed contents present in the root directory of an embedded framework". Spctl specifically mentions unsealed contents and when i try "codesign --verify --verbose=4 --deep" on any Qt framework. I have also tried verifying every component of the framework using the codesign command in the framework but it states that they are valid on disk and satisfies its Designated Requirement. The only file which has no code-signature in the framework is the CodeResources file created by the codesign itself and placed in the _CodeSignature folder.

                  I have created the following symbolic links:

                  QtGui.framework
                  |_ QtGui -> Versions/Current/QtGui
                  |_ Resources -> Versions/Current/Resources
                     |_ Info.plist
                  |_ Versions
                     |_ 5
                        |_ QtGui
                        |_ Resources
                        |_ _CodeSignature
                           |_ CodeResources
                      |_ A -> 5 
                      |_ Current -> 5
                  

                  Codesign command:

                  "codesign --force --verify --verbose --entitlements 'abc.plist' --sign 'Developer ID Application: ABC (XYZ)' --timestamp --options=runtime --strict QtGui.framework/Versions/5 "
                  
                  S Offline
                  S Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on 24 Mar 2020, 19:40 last edited by
                  #13

                  @angadhanoa hi and welcome to devnet,

                  IIRC, there was a thread recently about the same issue which was solved. Keep searching the forum.

                  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 25 Mar 2020, 19:01
                  0
                  • S SGaist
                    24 Mar 2020, 19:40

                    @angadhanoa hi and welcome to devnet,

                    IIRC, there was a thread recently about the same issue which was solved. Keep searching the forum.

                    A Offline
                    A Offline
                    angadhanoa
                    wrote on 25 Mar 2020, 19:01 last edited by
                    #14

                    @SGaist Thanks, I will. This is giving me a lot of headache. At first i was thinking that i have the same issue but that was not it. Once again, thank you. i will try to find that thread.

                    1 Reply Last reply
                    0
                    • SprezzaturaS Offline
                      SprezzaturaS Offline
                      Sprezzatura
                      wrote on 19 Oct 2020, 15:13 last edited by
                      #15

                      We had a similar problem. There does not appear to be any purpose for a lot of the stuff that Qt Creator piles into the ".app" file, and it interferes with Apple Notarization.

                      We solved the problem by simply creating a command file that deletes the conflicting files:

                      # Clean out detritus that prevents notarization
                      cd foo.app
                      find . -name "*.h" -delete
                      find . -name "*.prl" -delete
                      find . -name "*.cstemp" -delete
                      find . -name "Headers" -delete
                      find ./ -name "*_debug" -delete
                      
                      1 Reply Last reply
                      1

                      • Login

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