Apple Silicon and universal builds
Joshua Root
jmr at macports.org
Thu Jan 14 14:09:08 UTC 2021
Mark Bestley wrote:
> I have just got an Apple Silicon Mac Mini and am trying to install some ports
>
> I am trying to use just arm code. However some ports put a +universal variant as the default. This would not be a problem except some ports do not build if universal e.g. python38 and icu.
>
> Example ports that force unwanted +universal on are
>
> llvm-9.0 - which I managed to build using the manual fix in the icu ticket
>
> cargo which depends on python38. Now python38 works if arm build only.
>
> How do I force things to build for arm only.
>
> Why are +universal variants set as the default and how can you see which depenents are set this way (you can then force those to be single architecture)
This is happening when you install a port that does not support the
arm64 architecture, which means the only way to proceed on arm64
hardware is to install an x86_64 version. This means that the
dependencies need to support x86_64 as well, which results in them being
installed with +universal.
If you don't want this to happen, you could set universal_archs to just
'arm64' in macports.conf. This will cause an error when you try to
install any port that would normally trigger installation of a universal
dependency.
- Josh
More information about the macports-users
mailing list