summary refs log tree commit diff
path: root/pkgs/stdenv
diff options
context:
space:
mode:
authorPatrick Hilhorst <git@hilhorst.be>2018-06-07 16:16:14 +0200
committerPatrick Hilhorst <git@hilhorst.be>2018-10-29 14:51:22 +0100
commit149a55eca77279c683a48d274a2f295d8027977c (patch)
tree6b6fce1d4db37cf0e805e8abd1ceaeffe2969ba2 /pkgs/stdenv
parentefca8b4b97cab7653cc369973fb6267d160c494a (diff)
downloadnixlib-149a55eca77279c683a48d274a2f295d8027977c.tar
nixlib-149a55eca77279c683a48d274a2f295d8027977c.tar.gz
nixlib-149a55eca77279c683a48d274a2f295d8027977c.tar.bz2
nixlib-149a55eca77279c683a48d274a2f295d8027977c.tar.lz
nixlib-149a55eca77279c683a48d274a2f295d8027977c.tar.xz
nixlib-149a55eca77279c683a48d274a2f295d8027977c.tar.zst
nixlib-149a55eca77279c683a48d274a2f295d8027977c.zip
make-derivation: get position info from version
Diffstat (limited to 'pkgs/stdenv')
-rw-r--r--pkgs/stdenv/generic/make-derivation.nix2
1 files changed, 2 insertions, 0 deletions
diff --git a/pkgs/stdenv/generic/make-derivation.nix b/pkgs/stdenv/generic/make-derivation.nix
index 8fd58c3cbe91..dcf73a38a1d7 100644
--- a/pkgs/stdenv/generic/make-derivation.nix
+++ b/pkgs/stdenv/generic/make-derivation.nix
@@ -67,6 +67,8 @@ rec {
     , pos ? # position used in error messages and for meta.position
         (if attrs.meta.description or null != null
           then builtins.unsafeGetAttrPos "description" attrs.meta
+          else if attrs.version or null != null
+          then builtins.unsafeGetAttrPos "version" attrs
           else builtins.unsafeGetAttrPos "name" attrs)
     , separateDebugInfo ? false
     , outputs ? [ "out" ]