Hello folks,
I am having a bit hard time understanding the steps of compiling for M1 machines.
What is needed to compile vst3, AU, and AAX plugins for M1 native?
After compiling it for M1, is it going to work on the other none-M1 machines?
Hello folks,
I am having a bit hard time understanding the steps of compiling for M1 machines.
What is needed to compile vst3, AU, and AAX plugins for M1 native?
After compiling it for M1, is it going to work on the other none-M1 machines?
Xcode will make a universal binary which contains both intel and arm builds. You donāt need to do anything special!
But when you build from Xcode, you need to make sure to select āBuild for all Macsā instead of āBuild for my Macā.
Also for AAX you need to disable ARM for time being, see the other threads about AAX:
And if you need external libraries it becomes easily complicatedā¦
As @daniel says, things quickly get complicated if you are using any external libraries. I just spent the best part of a week rebuilding a load of 3rd party libraries for use in my applications.
Thank you very much for this quick responses.
AAX did not surprise me 
Iām not sure you even need to do that. Iāve tested both build for all and build for my and the binary comes out the same size on release mode. However the apple documentation does say that when building for a debug build it will only build for the current architecture to save time - but no one should be releasing a debug build anyway!
I think when set to release it follows the project settings no matter what:
Please correct me if I am mistaken however!
@Rory yeah, it took me a while to get going with the AAX library because of the whole universal binary thing. For standard JUCE stuff its nice and straightforward though!
You can build using either option, but you can only debug using the āBuild for my Macā option right?
Removing arm64 architecture only from the AAX target in the Xcode project did it for me. That builds the AAX plugin for Intel only, while all other plugins are built as univeral binaries.
Where can I find the setting āBuild for all Macsā?
On my version of Xcode it seems to be called āAny Macā now. However, as above, itās rare you actually need to change this.
To debug locally you have to switch to āMy Macā to run the build from XCode.
Rail
Thanks Guys,
I am not very experienced with Xcode so I appreciate your help. I can only run Xcode 14.2 because my Mac is on MacOS Monterey, and I canāt go higher. So in Xcode 14.2 the setting is āApple Silicon, Intelā. However, in the description on the page linked below the setting should be ā64-bit Intel and ARMā from Xcode 12.2 and forward. Are these two settings both indicating a universal plugin build for m1, M2 and Intel processors? Am I missing something? https://developer.apple.com/documentation/apple-silicon/building-a-universal-macos-binary
In this context Apple Silicon and ARM are the same thing, as is Intel and 64-bit Intel.
Thanks Anthony,
I appreciate it!
/Hans