From fac3d49e486cbca4306f991ed49687ac1230ed89 Mon Sep 17 00:00:00 2001 From: Jan Malakhovski Date: Wed, 3 Jan 2018 15:22:35 +0000 Subject: [PATCH] stdenv: provide `meta.name` --- pkgs/stdenv/generic/check-meta.nix | 1 + pkgs/stdenv/generic/make-derivation.nix | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/pkgs/stdenv/generic/check-meta.nix b/pkgs/stdenv/generic/check-meta.nix index ed4a0e2d841..13149c33f1c 100644 --- a/pkgs/stdenv/generic/check-meta.nix +++ b/pkgs/stdenv/generic/check-meta.nix @@ -153,6 +153,7 @@ let # Weirder stuff that doesn't appear in the documentation? knownVulnerabilities = listOf str; + name = str; version = str; tag = str; updateWalker = bool; diff --git a/pkgs/stdenv/generic/make-derivation.nix b/pkgs/stdenv/generic/make-derivation.nix index aef39fedb79..6c29e674688 100644 --- a/pkgs/stdenv/generic/make-derivation.nix +++ b/pkgs/stdenv/generic/make-derivation.nix @@ -201,6 +201,10 @@ rec { # passed to the builder and is not a dependency. But since we # include it in the result, it *is* available to nix-env for queries. meta = { + # `name` above includes cross-compilation cruft (and is under assert), + # lets have a clean always accessible version here. + inherit name; + # If the packager hasn't specified `outputsToInstall`, choose a default, # which is the name of `p.bin or p.out or p`; # if he has specified it, it will be overridden below in `// meta`.