From d78640533693167f9d4af1fa50ee9273d3a4e9e2 Mon Sep 17 00:00:00 2001 From: Ivar Scholten Date: Fri, 4 Mar 2022 14:28:34 +0100 Subject: [PATCH] treewide: don't unnecessary set dotnet-related env vars These have been moved to a setup hook in dotnet-{sdk,runtime,aspnetcore} --- .../build-support/dotnet/build-dotnet-module/default.nix | 3 --- .../build-dotnet-module/hooks/dotnet-configure-hook.sh | 2 -- .../continuous-integration/github-runner/default.nix | 5 ----- pkgs/development/tools/misc/netcoredbg/default.nix | 9 +-------- pkgs/servers/jellyfin/default.nix | 5 ----- pkgs/servers/nosql/eventstore/default.nix | 4 ---- 6 files changed, 1 insertion(+), 27 deletions(-) diff --git a/pkgs/build-support/dotnet/build-dotnet-module/default.nix b/pkgs/build-support/dotnet/build-dotnet-module/default.nix index e721b59decbe..85b8aa8afae1 100644 --- a/pkgs/build-support/dotnet/build-dotnet-module/default.nix +++ b/pkgs/build-support/dotnet/build-dotnet-module/default.nix @@ -129,9 +129,6 @@ in stdenvNoCC.mkDerivation (args // { # gappsWrapperArgs gets included when wrapping for dotnet, as to avoid double wrapping dontWrapGApps = args.dontWrapGApps or true; - DOTNET_NOLOGO = args.DOTNET_NOLOGO or true; # This disables the welcome message. - DOTNET_CLI_TELEMETRY_OPTOUT = args.DOTNET_CLI_TELEMETRY_OPTOUT or true; - passthru = { fetch-deps = writeScript "fetch-${pname}-deps" '' set -euo pipefail diff --git a/pkgs/build-support/dotnet/build-dotnet-module/hooks/dotnet-configure-hook.sh b/pkgs/build-support/dotnet/build-dotnet-module/hooks/dotnet-configure-hook.sh index 3ca89fdc095e..59daacbac0ed 100644 --- a/pkgs/build-support/dotnet/build-dotnet-module/hooks/dotnet-configure-hook.sh +++ b/pkgs/build-support/dotnet/build-dotnet-module/hooks/dotnet-configure-hook.sh @@ -9,8 +9,6 @@ dotnetConfigureHook() { parallelFlag="--disable-parallel" fi - export HOME=$(mktemp -d) - for project in ${projectFile[@]} ${testProjectFile[@]}; do env \ dotnet restore "$project" \ diff --git a/pkgs/development/tools/continuous-integration/github-runner/default.nix b/pkgs/development/tools/continuous-integration/github-runner/default.nix index 7818f7464bad..222ffb0688fe 100644 --- a/pkgs/development/tools/continuous-integration/github-runner/default.nix +++ b/pkgs/development/tools/continuous-integration/github-runner/default.nix @@ -102,11 +102,6 @@ stdenv.mkDerivation rec { configurePhase = '' runHook preConfigure - # Set up Nuget dependencies - export HOME=$(mktemp -d) - export DOTNET_CLI_TELEMETRY_OPTOUT=1 - export DOTNET_NOLOGO=1 - # Never use nuget.org nuget sources Disable -Name "nuget.org" diff --git a/pkgs/development/tools/misc/netcoredbg/default.nix b/pkgs/development/tools/misc/netcoredbg/default.nix index 1907eb8b3637..cb0c1cdc8ec7 100644 --- a/pkgs/development/tools/misc/netcoredbg/default.nix +++ b/pkgs/development/tools/misc/netcoredbg/default.nix @@ -24,14 +24,7 @@ let unmanaged = clangStdenv.mkDerivation rec { inherit src pname version; - nativeBuildInputs = [ cmake ]; - - # Building the "unmanaged part" still involves compiling C# code. - preBuild = '' - export HOME=$(mktemp -d) - export DOTNET_CLI_TELEMETRY_OPTOUT=1 - export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1 - ''; + nativeBuildInputs = [ cmake dotnet-sdk ]; hardeningDisable = [ "strictoverflow" ]; diff --git a/pkgs/servers/jellyfin/default.nix b/pkgs/servers/jellyfin/default.nix index 4dce2a7258fa..814d8eecdc38 100644 --- a/pkgs/servers/jellyfin/default.nix +++ b/pkgs/servers/jellyfin/default.nix @@ -70,11 +70,6 @@ stdenv.mkDerivation rec { configurePhase = '' runHook preConfigure - export HOME=$(mktemp -d) - - export DOTNET_CLI_TELEMETRY_OPTOUT=1 - export DOTNET_NOLOGO=1 - nuget sources Add -Name nixos -Source "$PWD/nixos" nuget init "$nugetDeps" "$PWD/nixos" diff --git a/pkgs/servers/nosql/eventstore/default.nix b/pkgs/servers/nosql/eventstore/default.nix index 769c45ffc6c5..035d906b2bdb 100644 --- a/pkgs/servers/nosql/eventstore/default.nix +++ b/pkgs/servers/nosql/eventstore/default.nix @@ -43,10 +43,6 @@ stdenv.mkDerivation rec { ''; buildPhase = '' - mkdir home - export HOME=$PWD/home - export DOTNET_CLI_TELEMETRY_OPTOUT=1 - export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1 export FrameworkPathOverride=${mono}/lib/mono/4.7.1-api # disable default-source so nuget does not try to download from online-repo