diff options
author | Sander van der Burg <svanderburg@gmail.com> | 2021-03-29 21:17:56 +0200 |
---|---|---|
committer | Sander van der Burg <sander.van.der.burg@mendix.com> | 2021-03-29 21:24:00 +0200 |
commit | 44704440ef6d152b83604d3f953def69f8b41551 (patch) | |
tree | affad958c333704fddf948f41a5ed06b723022ee | |
parent | 63be3d6498de5106aa88dc4bdb54dd806070d8d9 (diff) |
releaseTools: fix nixBuild function
Without this fix, I can no longer build anything with releaseTools.nixBuild {}. A job typically fails with: $ nix-build release.nix -A build.basic.x86_64-linux --show-trace error: while evaluating the attribute 'lib' of the derivation 'libnixxml-0.1pre1234' at /home/sander/teststuff/nixpkgs/pkgs/build-support/release/nix-build.nix:89:5: cannot coerce a set to a string, at /home/sander/teststuff/nixpkgs/pkgs/build-support/release/nix-build.nix:89:5 This is caused by the fact that `lib' is propagated as a parameter, which is a function. Functions cannot be converted to strings.
-rw-r--r-- | pkgs/build-support/release/nix-build.nix | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkgs/build-support/release/nix-build.nix b/pkgs/build-support/release/nix-build.nix index 97df52eaced26..ac51b90e01639 100644 --- a/pkgs/build-support/release/nix-build.nix +++ b/pkgs/build-support/release/nix-build.nix @@ -83,9 +83,9 @@ stdenv.mkDerivation ( ''; } - // args // + // removeAttrs args [ "lib" ] # Propagating lib causes the evaluation to fail, because lib is a function that can't be converted to a string - { + // { name = name + (if src ? version then "-" + src.version else ""); postHook = '' |