[macOS] Only run Mono in 32bit mode when the GUI is launched #2893
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
The release of macOS Catalina marked the death of 32-bit applications on Apple's platform.
This means, our GUI is no longer runnable on macOS due to Mono's WinForms implementation being 32-bit only:
#2270 hardcoded
--arch=32
as argument for Mono, which now prevents users from using the CUI or TUI, if they want to.Changes
Now there's a check for arguments in the launch script for macOS. If it's none or
gui
, the flag--arch=32
is used for Mono, else it's--arch=64
.Mono's man page says the following, just FYI:
If I understood it right that .apps behave like executables, it should enable to run
ckan.app consoleui
and more again.Correct me if I'm wrong please.
Problems
This breaks commands like
ckan --verbose
(on macOS only, of course), which normally should run the GUI with verbose logging in the console. But I don't think a lot of people used this, and they can still addgui
in the middle to make it work again, sockan gui --verbose
.Also, I did NOT test this, since I'm lacking Apple hardware and as far as I know does Apple a good job preventing macOS to work in VMs.