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. Intermittent problem with macdeployqt
Forum Updated to NodeBB v4.3 + New Features

Intermittent problem with macdeployqt

Scheduled Pinned Locked Moved Solved Installation and Deployment
16 Posts 4 Posters 3.6k Views 2 Watching
  • 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.
  • K Offline
    K Offline
    Kasungu
    wrote on last edited by
    #6

    One more item: Maybe my .pro file is not correct...

    QT += core
    QT += gui
    QT += widgets
    QT += printsupport

    VERSION = "10.0"
    DEFINES = "MacX64"

    CONFIG -= console
    CONFIG += app_bundle
    CONFIG += staticlib

    TEMPLATE = app
    TARGET = $$PWD/bin/Ifstool10.0
    INCLUDEPATH += ../hdr

    SOURCES +=
    main.cpp
    ifstoolMainWindow.cpp
    ifstool.cpp
    subclassqapp.cpp
    ifs2qt.cpp
    ifstoolChildWindow.cpp
    ifsOp.cpp
    plotMainWindow.cpp
    qcustomplot.cpp

    FORMS +=
    plotMainWindow.ui

    HEADERS +=
    main.h
    ../hdr/flip.h
    ../hdr/ifs.h
    ../hdr/ifsdocs.h
    ../hdr/ifsequ.h
    ../hdr/ifserr.h
    ../hdr/ifsmatrix.h
    ../hdr/ifstypes.h
    ../hdr/nicedefs.h
    ../hdr/resample.h
    ../hdr/rfft.h
    ../hdr/stddefs.h
    ../hdr/cclC4.h
    ifstoolMainWindow.h
    ifstool.h
    generictypes.h
    subclassqapp.h
    ifs2qt.h
    ifstoolChildWindow.h
    ifsOp.h
    plotMainWindow.h
    qcustomplot.h

    macx {
    QMAKE_MAC_SDK=macosx10.12
    }

    macx: LIBS += -L$$PWD/../lib/macX64/ -lifs

    INCLUDEPATH += $$PWD/../lib/macX64/ifslib
    DEPENDPATH += $$PWD/../lib/macX64/ifslib

    macx: PRE_TARGETDEPS += $$PWD/../lib/macX64/libifs.a

    RESOURCES +=
    images.qrc

    Plugins = PlugIns

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #7

      Can you check with a more recent version of Qt ? IIRC the current is 5.9.3 but you can also test 5.10

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

      1 Reply Last reply
      0
      • K Offline
        K Offline
        Kasungu
        wrote on last edited by
        #8

        I just built 5.9.3 and tried it. It failed in an identical way. I can try 5.4, but I fear this is not the problem.

        1 Reply Last reply
        0
        • K Offline
          K Offline
          Kasungu
          wrote on last edited by
          #9

          I downloaded and tried 5.4. This fails with

          This application failed to start because it could not find or load the Qt platform plugin "cocoa" and that is running under Qt Creator.

          I tried the complete download/install on this twice. I'll go back to 5.9.3.
          Wesley

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #10

            Is your code available somewhere to test the deployment ?

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

            1 Reply Last reply
            0
            • K Offline
              K Offline
              Kasungu
              wrote on last edited by
              #11

              The source code is not on a public cloud at the moment, but I'll be glad to send it to you. But how do we do it without making our actual email addresses public? I have used Wetransfer and Dropbox both.

              J.HilkJ 1 Reply Last reply
              0
              • K Kasungu

                The source code is not on a public cloud at the moment, but I'll be glad to send it to you. But how do we do it without making our actual email addresses public? I have used Wetransfer and Dropbox both.

                J.HilkJ Offline
                J.HilkJ Offline
                J.Hilk
                Moderators
                wrote on last edited by J.Hilk
                #12

                @Kasungu This may be a stupid question, but are you sure, that you use the correct macdeployqt-tool ?

                Each installation of Qt - 5.9.3, 5.92, 5.4 etc. - each come with their own deploy-tool. If you're using the 5.4 tool for a 5.9.3 binary, than theres a high chance that it won't work.

                A file is copied into the folder, but the wrong one.


                Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


                Q: What's that?
                A: It's blue light.
                Q: What does it do?
                A: It turns blue.

                1 Reply Last reply
                0
                • K Offline
                  K Offline
                  Kasungu
                  wrote on last edited by
                  #13

                  It was a great idea! I was excited, but I checked and unfortunately I had done it right. But I double-checked, made sure no other versions of Qt existed, rebuilt using the version of Creator which was in 5.9.3, etc. It still fails in the same way.
                  (By the way, when I run the version of Creator in 5.9.3, and hit About Creator, I get
                  "Based on Qt 5.9.2". I presume this is because Creator did not change between 5.9.2 and 5.9.3, and this message didn't get changed. Right?)

                  Sigh..

                  mrjjM 1 Reply Last reply
                  0
                  • K Kasungu

                    It was a great idea! I was excited, but I checked and unfortunately I had done it right. But I double-checked, made sure no other versions of Qt existed, rebuilt using the version of Creator which was in 5.9.3, etc. It still fails in the same way.
                    (By the way, when I run the version of Creator in 5.9.3, and hit About Creator, I get
                    "Based on Qt 5.9.2". I presume this is because Creator did not change between 5.9.2 and 5.9.3, and this message didn't get changed. Right?)

                    Sigh..

                    mrjjM Offline
                    mrjjM Offline
                    mrjj
                    Lifetime Qt Champion
                    wrote on last edited by
                    #14

                    @Kasungu said in Intermittent problem with macdeployqt:

                    "Based on Qt 5.9.2".

                    Means what Qt Creator was build with and it is not related to the version of Qt
                    you are using to build your application.
                    In fact you can have multiple version of Qt installed and use in the same Creator.

                    1 Reply Last reply
                    0
                    • K Offline
                      K Offline
                      Kasungu
                      wrote on last edited by
                      #15

                      I found the fix! all it required was the correct switch used withmacdeployqt:

                      /Users/[PathtoQt]/Qt/5.9.3/clang_64/bin/macdeployqt [space] /Users/[pathtoapp]/ThisApp.app - [note the dash] executable=/Users/[pathtoapp]ThisApp.app/Contents/MacOS/ThisApp

                      The online manual says this about that switch:

                      -executable=<path> Let the given executable also use the deployed frameworks

                      Perhaps this could be described a bit more clearly, since if you do this, all the stuff using Install_name_tool isn't needed. (Finding this took me weeks). Of course, I am not a Qt guru, maybe it's just me.

                      1 Reply Last reply
                      3
                      • SGaistS Offline
                        SGaistS Offline
                        SGaist
                        Lifetime Qt Champion
                        wrote on last edited by
                        #16

                        It's a bit surprising, in most cases you shouldn't need that option.

                        Anyway, glad you found out and thanks for sharing ! :)

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

                        1 Reply Last reply
                        0

                        • Login

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