about summary refs log tree commit diff
path: root/pkgs/build-support/dotnet
diff options
context:
space:
mode:
author7c6f434c <7c6f434c@mail.ru>2023-04-17 14:08:21 +0000
committerGitHub <noreply@github.com>2023-04-17 14:08:21 +0000
commit17b4ad7c2ff4fbf3afdbf96d69232888c93edab9 (patch)
tree7a84f62791168512017a08de1e6e197a1d86867f /pkgs/build-support/dotnet
parent656eb4156d06d818c3f9630b2d6dc0fa7ad339e5 (diff)
parent8c8524bc9a95f9a0ba7691b097804f928781d162 (diff)
Merge pull request #217587 from winterqt/build-dotnet-module-darwin-sandbox
buildDotnetModule: fix sandboxed builds on darwin
Diffstat (limited to 'pkgs/build-support/dotnet')
-rw-r--r--pkgs/build-support/dotnet/build-dotnet-module/default.nix6
1 files changed, 5 insertions, 1 deletions
diff --git a/pkgs/build-support/dotnet/build-dotnet-module/default.nix b/pkgs/build-support/dotnet/build-dotnet-module/default.nix
index 8858d4e9877dd..bae7148283663 100644
--- a/pkgs/build-support/dotnet/build-dotnet-module/default.nix
+++ b/pkgs/build-support/dotnet/build-dotnet-module/default.nix
@@ -284,4 +284,8 @@ stdenvNoCC.mkDerivation (args // {
   } // args.passthru or { };
 
   meta = (args.meta or { }) // { inherit platforms; };
-})
+}
+  # ICU tries to unconditionally load files from /usr/share/icu on Darwin, which makes builds fail
+  # in the sandbox, so disable ICU on Darwin. This, as far as I know, shouldn't cause any built packages
+  # to behave differently, just the dotnet build tool.
+  // lib.optionalAttrs stdenvNoCC.isDarwin { DOTNET_SYSTEM_GLOBALIZATION_INVARIANT = 1; })