mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-18 10:53:52 +00:00
Filter null elements from dependency lists to keep hashes stable.
svn path=/nixpkgs/trunk/; revision=28434
This commit is contained in:
parent
369832838b
commit
31654fc153
@ -11,6 +11,15 @@
|
|||||||
"isLibrary" "isExecutable"
|
"isLibrary" "isExecutable"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Stuff happening after the user preferences have been processed. We remove
|
||||||
|
# internal attributes and strip null elements from the dependency lists, all
|
||||||
|
# in the interest of keeping hashes stable.
|
||||||
|
postprocess =
|
||||||
|
x : (removeAttrs x internalAttrs) // {
|
||||||
|
buildInputs = stdenv.lib.filter (y : ! (y == null)) x.buildInputs;
|
||||||
|
propagatedBuildInputs = stdenv.lib.filter (y : ! (y == null)) x.propagatedBuildInputs;
|
||||||
|
};
|
||||||
|
|
||||||
defaults =
|
defaults =
|
||||||
self : { # self is the final version of the attribute set
|
self : { # self is the final version of the attribute set
|
||||||
|
|
||||||
@ -142,5 +151,5 @@
|
|||||||
# in Cabal derivations.
|
# in Cabal derivations.
|
||||||
inherit stdenv ghc;
|
inherit stdenv ghc;
|
||||||
};
|
};
|
||||||
in stdenv.mkDerivation (removeAttrs ((rec { f = defaults f // args f; }).f) internalAttrs) ;
|
in stdenv.mkDerivation (postprocess ((rec { f = defaults f // args f; }).f)) ;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user