From ba2f31b6db0d71969bb1fcbeaed30925a935a5b0 Mon Sep 17 00:00:00 2001 From: zimbatm Date: Tue, 21 Jun 2022 15:37:15 +0200 Subject: buildDotnetModule: allow passing derivations to nugetDeps Sometimes I want to pass a different implementation of `mkNugetDeps`. For example in private repos, it can be handy to use `__noChroot = true` and bypass the deps.nix generation altogether. Or some Nuget packages ship with ELF binaries that need to be patched, and that's best done as soon as possible. --- pkgs/build-support/dotnet/build-dotnet-module/default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'pkgs/build-support/dotnet/build-dotnet-module/default.nix') diff --git a/pkgs/build-support/dotnet/build-dotnet-module/default.nix b/pkgs/build-support/dotnet/build-dotnet-module/default.nix index fa987237a75..96e7596ed62 100644 --- a/pkgs/build-support/dotnet/build-dotnet-module/default.nix +++ b/pkgs/build-support/dotnet/build-dotnet-module/default.nix @@ -78,7 +78,9 @@ let then linkFarmFromDrvs "${name}-project-references" projectReferences else null; - _nugetDeps = mkNugetDeps { inherit name; nugetDeps = import nugetDeps; }; + _nugetDeps = if lib.isDerivation nugetDeps + then nugetDeps + else mkNugetDeps { inherit name; nugetDeps = import nugetDeps; }; nuget-source = mkNugetSource { name = "${name}-nuget-source"; -- cgit 1.4.1