nixpkgs/pkgs/development/compilers/zig/0.13
Alex James cae03b78b4
zig: fix build on Darwin with sandbox enabled
During stage 3 of compilation, Zig calls `std.zig.system.darwin.macos.detect`,
which parses /System/Library/CoreServices/.SystemVersionPlatform.plist and
/System/Library/CoreServices/SystemVersion.plist[^1] to determine the OS
version. These paths are inaccessible when the sandbox is enabled, which causes
the build to fail with `OSVersionDetectionFail`[^2]. Fix the build with the
relaxed sandbox option by adding these paths to `__impureHostDeps`.

[^1]: cd62005f19/lib/std/zig/system/darwin/macos.zig
[^2]: https://github.com/NixOS/nixpkgs/issues/287861#issuecomment-2148703491
2024-06-16 17:51:10 -05:00
..
default.nix
hook.nix
setup-hook.sh