coqPackages: refactor
Coq packages that depend on others need to be recompiled when the dependencies are updated, so we make the whole `coqPackages` overridable by `overrideScope'`, using `lib.makeScope`.
This commit is contained in:
parent
ed426e4df8
commit
f7bf3d2239
|
@ -2,8 +2,9 @@
|
||||||
|
|
||||||
let
|
let
|
||||||
mkCoqPackages' = self: coq:
|
mkCoqPackages' = self: coq:
|
||||||
let callPackage = newScope self ; in rec {
|
let newScope = self.newScope;
|
||||||
inherit callPackage coq;
|
callPackage = self.callPackage; in {
|
||||||
|
inherit coq;
|
||||||
coqPackages = self;
|
coqPackages = self;
|
||||||
|
|
||||||
contribs = recurseIntoAttrs
|
contribs = recurseIntoAttrs
|
||||||
|
@ -75,7 +76,7 @@ in rec {
|
||||||
* a `dontFilter` attribute into the Coq derivation.
|
* a `dontFilter` attribute into the Coq derivation.
|
||||||
*/
|
*/
|
||||||
mkCoqPackages = coq:
|
mkCoqPackages = coq:
|
||||||
let self = mkCoqPackages' self coq; in
|
let self = lib.makeScope newScope (lib.flip mkCoqPackages' coq); in
|
||||||
if coq.dontFilter or false then self
|
if coq.dontFilter or false then self
|
||||||
else filterCoqPackages coq self;
|
else filterCoqPackages coq self;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue