From 88e8d87fedcd17d7125d970fc2e6ff03c9884d6a Mon Sep 17 00:00:00 2001 From: David McFarland Date: Mon, 11 Mar 2024 22:32:42 -0300 Subject: [PATCH] dotnet: strip debug info This reduces the sdk closure size from 739.2M/2.5G to 494.5M/584.0M. --- pkgs/development/compilers/dotnet/vmr.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/development/compilers/dotnet/vmr.nix b/pkgs/development/compilers/dotnet/vmr.nix index 36b75c40e6c8..cb11f0a3f064 100644 --- a/pkgs/development/compilers/dotnet/vmr.nix +++ b/pkgs/development/compilers/dotnet/vmr.nix @@ -311,6 +311,13 @@ in stdenv.mkDerivation rec { runHook postInstall ''; + # dotnet cli is in the root, so we need to strip from there + # TODO: should we install in $out/share/dotnet? + stripDebugList = [ "." ]; + # stripping dlls results in: + # Failed to load System.Private.CoreLib.dll (error code 0x8007000B) + stripExclude = [ "*.dll" ]; + passthru = { inherit releaseManifest buildRid targetRid; icu = _icu;