Application on MacOS not producing a .app gile so I can create a shippable executable
-
@DiBosco said in Application on MacOS not producing a .app gile so I can create a shippable executable:
The one thing I could do at this point is delete 5.6.3 from the M1 Mac, install the latest version of Qt and see if that creates the app file, but as we have to build against 5.6.3 for licence reasons I'm not really sure that helps.
Unless I am mistaken you can just download and install using online installer into a different folder and it should not interfere. should not
Xcode is Apple SDK, think of it as all the
-dev
packages in Linux plus toolkits (compilers, debuggers, whatnot). It is essential.So, give it a go - if it still fails to build a proper .app on the fresh Qt we know it's something we can probably fix with a means to reproduce errors and hopefully that could fix your main issue. If on the other hand it works just fine... We'll see.
-
If you are locked to that old version of Qt, you might want to consider virtualization and run an older version of macOS + Xcode that was officially supported by that version of Qt.
That said, as other pointed out, a static Qt version on macOS is really unusual. This platform rather uses frameworks and dynamic libraries in their bundles. -
@SGaist said in Application on MacOS not producing a .app gile so I can create a shippable executable:
That said, as other pointed out, a static Qt version on macOS is really unusual. This platform rather uses frameworks and dynamic libraries in their bundles.
As I said in my previous post, the static thing is a red herring. Whether it is built dynamic or static, I get the the same lack of .app.
I'll try the latest version on the M1 Mac and see what happens next week, have run out of time this week to try it.
-
OK, I ended up with unexpected spare time this evening so installed the latest version of Qt and it still doesn't produce a .app file.
At least with this latest version I can click on the executable from the build directory and it runs, with 5.6.3 I get a crash report that gives some Rosetta data.
-
-
@artwaw said in Application on MacOS not producing a .app gile so I can create a shippable executable:
@DiBosco said in Application on MacOS not producing a .app gile so I can create a shippable executable:
I can click on the executable from the build directory
So doesn't produce the .app but does produce executable? Just plain binary?
Yes, that's right.
This is, for clarity, on the M1 Mac. The 5.6.3 program executable crashes, the latest version 6.something exectutable runs if you click on it in the build directory.
Also for clarity, this is just an hello world program I've tried it with, written from scratch.
-
@artwaw said in Application on MacOS not producing a .app gile so I can create a shippable executable:
@DiBosco what if you try the default GUI widgets application template from the creator?
That's what I tried when I made my hello world app.
-
Ah, sorry,
written from scratch
- I misunderstood that.Might be weird and it's been ages since I tried, but: what about two-step approach? You can ask qmake to prepare build files for the Xcode with
qmake -spec macx-xcode project.pro
orqmake ~/src/myapp -spec macx-xcode
- the open the result in Xcode and try to build there?I am running out of ideas...
-
I finally sussed this. It was a number of things. In case it helps anyone on the future:
I found an article that suggested doing this on the command line in the source code folder:
make clean
qmake -config release
makeI still didn't have a .app in Finder but I did have one in the console so I am guessing ******** Finder is one of the biggest issues here. Probably does that really annoying thing Windows Explorer does by hiding extensions. Have never understood why a file explorer would do that. I could at this point run the macdeploy tool from the command line and produce an exxecutable.
At this point the STATIC build was a problem. Taking that out, meant it would run as a stand alone app.
This is all on 5.6.3 so the Qt version was also nothing to do with it.
-
Application bundle on macOS are indeed a special case. They are basically a folder with an extension following a special structure.
Here you have the complete explanation in the Apple documentation.
The Qt macOS deployment guide also talks about it.