Describe the bug
This is sort-of related to nixpkgs itself, but there's no issue template for non-package-related isssues there.
For MacOS, there seem to be twothree different system strings at the moment: aarch64-darwin, aarch64-apple-darwin and arm64-apple-darwin. I can't find any documentation describing how they differ. As a result, most packages are configured with options for aarch64-darwin and not arm64-apple-darwin. For example: nix-community/home-manager#6878
My system is showing as arm64-apple-darwin when configured as a standalone Nix installation over MacOS (not a nix-darwin setup). I don't have access to an unmanaged mac, thus I can't test a nix-darwin setup sadly.
$ nix eval nixpkgs#legacyPackages.aarch64-darwin.stdenv.hostPlatform.config
"arm64-apple-darwin"
However, when packages specify supported platforms, the system string seems to be aarch64-apple-darwin, so could this be an issue with the package derivation logic itself? (logs from linked issue):
error: Package ‘firefox-137.0.1’ in /nix/store/hzaj4d6ari2wq2cbg1j60n9zw42gnshy-source/pkgs/applications/networking/browsers/firefox/wrapper.nix:504 is not available on the requested hostPlatform:
hostPlatform.config = "aarch64-apple-darwin"
package.meta.platforms = [
"i686-cygwin"
"x86_64-cygwin"
...
]
This would be super weird, because it would mean that the hostPlatform.config has different values in make-derivation-nix vs check-meta-nix, as the invocation simply inherits the hostPlatform? Alternatively, there could be some logic that overrides this value that only shows up when doing a build versus evaluating the output?
The main two questions are:
- Why are they different?
- Should they be different? If not, how do we fix it?
EDIT: This is the whole extent to which I know how to debug this on my own, I would highly appreciate some guidance forward, as it's highly likely this impacts other users as well (a quick search shows up multiple aarch64-apple-darwin results). I am happy to pour some time into this, but unpicking the different places this value is set (and where it's derived from in the first place) is very elusive to me atm.
Steps To Reproduce
- Install Nix multi-user as a standalone installation on MacOS
Expected behavior
If the system strings should be different, then have documentation explaining how and how to handle them (and the differences). If not, realign the system strings.
Metadata
nix-env (Nix) 2.26.3
Additional context
Checklist
Add 👍 to issues you find important.
Describe the bug
This is sort-of related to
nixpkgsitself, but there's no issue template for non-package-related isssues there.For MacOS, there seem to be
twothree different system strings at the moment:aarch64-darwin,aarch64-apple-darwinandarm64-apple-darwin. I can't find any documentation describing how they differ. As a result, most packages are configured with options foraarch64-darwinand notarm64-apple-darwin. For example: nix-community/home-manager#6878My system is showing as
arm64-apple-darwinwhen configured as a standalone Nix installation over MacOS (not a nix-darwin setup). I don't have access to an unmanaged mac, thus I can't test a nix-darwin setup sadly.However, when packages specify supported platforms, the system string seems to be
aarch64-apple-darwin, so could this be an issue with the package derivation logic itself? (logs from linked issue):This would be super weird, because it would mean that the
hostPlatform.confighas different values inmake-derivation-nixvscheck-meta-nix, as the invocation simply inherits thehostPlatform? Alternatively, there could be some logic that overrides this value that only shows up when doing a build versus evaluating the output?The main two questions are:
EDIT: This is the whole extent to which I know how to debug this on my own, I would highly appreciate some guidance forward, as it's highly likely this impacts other users as well (a quick search shows up multiple
aarch64-apple-darwinresults). I am happy to pour some time into this, but unpicking the different places this value is set (and where it's derived from in the first place) is very elusive to me atm.Steps To Reproduce
Expected behavior
If the system strings should be different, then have documentation explaining how and how to handle them (and the differences). If not, realign the system strings.
Metadata
nix-env (Nix) 2.26.3
Additional context
Checklist
Add 👍 to issues you find important.