all-packages.nix: introduce and use dontRecurseIntoAttrs

This commit is contained in:
Jan Malakhovski 2018-08-18 17:58:23 +00:00
parent 828759f9b8
commit 8f86439f75

View File

@ -64,6 +64,14 @@ in
# inside the set for derivations. # inside the set for derivations.
recurseIntoAttrs = attrs: attrs // { recurseForDerivations = true; }; recurseIntoAttrs = attrs: attrs // { recurseForDerivations = true; };
# This is intended to be the reverse of recurseIntoAttrs, as it is
# defined now it exists mainly for documentation purposes, but you
# can also override this with recurseIntoAttrs to recurseInto all
# the Attrs which is useful for testing massive changes. Ideally,
# every package subset not marked with recurseIntoAttrs should be
# marked with this.
dontRecurseIntoAttrs = x: x;
stringsWithDeps = lib.stringsWithDeps; stringsWithDeps = lib.stringsWithDeps;
### Evaluating the entire Nixpkgs naively will fail, make failure fast ### Evaluating the entire Nixpkgs naively will fail, make failure fast
@ -1624,7 +1632,7 @@ in
roundcube = callPackage ../servers/roundcube { }; roundcube = callPackage ../servers/roundcube { };
roundcubePlugins = callPackage ../servers/roundcube/plugins { }; roundcubePlugins = dontRecurseIntoAttrs (callPackage ../servers/roundcube/plugins { });
rsbep = callPackage ../tools/backup/rsbep { }; rsbep = callPackage ../tools/backup/rsbep { };
@ -2428,7 +2436,7 @@ in
emscripten = callPackage ../development/compilers/emscripten { }; emscripten = callPackage ../development/compilers/emscripten { };
emscriptenfastcompPackages = callPackage ../development/compilers/emscripten/fastcomp { }; emscriptenfastcompPackages = dontRecurseIntoAttrs (callPackage ../development/compilers/emscripten/fastcomp { });
emscriptenfastcomp = emscriptenfastcompPackages.emscriptenfastcomp; emscriptenfastcomp = emscriptenfastcompPackages.emscriptenfastcomp;
@ -2760,9 +2768,9 @@ in
fusuma = callPackage ../tools/inputmethods/fusuma {}; fusuma = callPackage ../tools/inputmethods/fusuma {};
fdbPackages = callPackage ../servers/foundationdb { fdbPackages = dontRecurseIntoAttrs (callPackage ../servers/foundationdb {
stdenv49 = overrideCC stdenv gcc49; stdenv49 = overrideCC stdenv gcc49;
}; });
inherit (fdbPackages) inherit (fdbPackages)
foundationdb51 foundationdb51
@ -3862,17 +3870,17 @@ in
openssl = openssl_1_1; openssl = openssl_1_1;
}; };
nodePackages_10_x = callPackage ../development/node-packages/default-v10.nix { nodePackages_10_x = dontRecurseIntoAttrs (callPackage ../development/node-packages/default-v10.nix {
nodejs = pkgs.nodejs-10_x; nodejs = pkgs.nodejs-10_x;
}; });
nodePackages_8_x = callPackage ../development/node-packages/default-v8.nix { nodePackages_8_x = dontRecurseIntoAttrs (callPackage ../development/node-packages/default-v8.nix {
nodejs = pkgs.nodejs-8_x; nodejs = pkgs.nodejs-8_x;
}; });
nodePackages_6_x = callPackage ../development/node-packages/default-v6.nix { nodePackages_6_x = dontRecurseIntoAttrs (callPackage ../development/node-packages/default-v6.nix {
nodejs = pkgs.nodejs-6_x; nodejs = pkgs.nodejs-6_x;
}; });
nodePackages = nodePackages_10_x; nodePackages = nodePackages_10_x;
@ -4868,7 +4876,7 @@ in
plan9port = callPackage ../tools/system/plan9port { }; plan9port = callPackage ../tools/system/plan9port { };
platformioPackages = callPackage ../development/arduino/platformio { }; platformioPackages = dontRecurseIntoAttrs (callPackage ../development/arduino/platformio { });
platformio = platformioPackages.platformio-chrootenv; platformio = platformioPackages.platformio-chrootenv;
platinum-searcher = callPackage ../tools/text/platinum-searcher { }; platinum-searcher = callPackage ../tools/text/platinum-searcher { };
@ -7012,9 +7020,9 @@ in
haskell = callPackage ./haskell-packages.nix { }; haskell = callPackage ./haskell-packages.nix { };
haskellPackages = haskell.packages.ghc863.override { haskellPackages = dontRecurseIntoAttrs (haskell.packages.ghc863.override {
overrides = config.haskellPackageOverrides or haskell.packageOverrides; overrides = config.haskellPackageOverrides or haskell.packageOverrides;
}; });
inherit (haskellPackages) ghc; inherit (haskellPackages) ghc;
@ -7103,9 +7111,9 @@ in
icedtea_web = icedtea8_web; icedtea_web = icedtea8_web;
idrisPackages = callPackage ../development/idris-modules { idrisPackages = dontRecurseIntoAttrs (callPackage ../development/idris-modules {
idris-no-deps = haskellPackages.idris; idris-no-deps = haskellPackages.idris;
}; });
idris = idrisPackages.with-packages [ idrisPackages.base ] ; idris = idrisPackages.with-packages [ idrisPackages.base ] ;
@ -9059,7 +9067,7 @@ in
selendroid = callPackage ../development/tools/selenium/selendroid { }; selendroid = callPackage ../development/tools/selenium/selendroid { };
sconsPackages = callPackage ../development/tools/build-managers/scons { }; sconsPackages = dontRecurseIntoAttrs (callPackage ../development/tools/build-managers/scons { });
scons = sconsPackages.scons_latest; scons = sconsPackages.scons_latest;
mill = callPackage ../development/tools/build-managers/mill { }; mill = callPackage ../development/tools/build-managers/mill { };
@ -10039,7 +10047,7 @@ in
# A GMP fork # A GMP fork
mpir = callPackage ../development/libraries/mpir {}; mpir = callPackage ../development/libraries/mpir {};
gns3Packages = callPackage ../applications/networking/gns3 { }; gns3Packages = dontRecurseIntoAttrs (callPackage ../applications/networking/gns3 { });
gns3-gui = gns3Packages.guiStable; gns3-gui = gns3Packages.guiStable;
gns3-server = gns3Packages.serverStable; gns3-server = gns3Packages.serverStable;
@ -13308,8 +13316,8 @@ in
quicklispPackagesFor = clwrapper: callPackage ../development/lisp-modules/quicklisp-to-nix.nix { quicklispPackagesFor = clwrapper: callPackage ../development/lisp-modules/quicklisp-to-nix.nix {
inherit clwrapper; inherit clwrapper;
}; };
quicklispPackagesClisp = quicklispPackagesFor (wrapLisp clisp); quicklispPackagesClisp = dontRecurseIntoAttrs (quicklispPackagesFor (wrapLisp clisp));
quicklispPackagesSBCL = quicklispPackagesFor (wrapLisp sbcl); quicklispPackagesSBCL = dontRecurseIntoAttrs (quicklispPackagesFor (wrapLisp sbcl));
quicklispPackages = quicklispPackagesSBCL; quicklispPackages = quicklispPackagesSBCL;
quicklispPackages_asdf_3_1 = quicklispPackagesFor quicklispPackages_asdf_3_1 = quicklispPackagesFor
((wrapLisp sbcl).override { asdf = asdf_3_1; }); ((wrapLisp sbcl).override { asdf = asdf_3_1; });
@ -13371,9 +13379,9 @@ in
packages = []; packages = [];
}; };
rPackages = callPackage ../development/r-modules { rPackages = dontRecurseIntoAttrs (callPackage ../development/r-modules {
overrides = (config.rPackageOverrides or (p: {})) pkgs; overrides = (config.rPackageOverrides or (p: {})) pkgs;
}; });
### SERVERS ### SERVERS
@ -13408,7 +13416,7 @@ in
subversion = pkgs.subversion.override { httpServer = true; inherit apacheHttpd; }; subversion = pkgs.subversion.override { httpServer = true; inherit apacheHttpd; };
}; };
apacheHttpdPackages_2_4 = apacheHttpdPackagesFor pkgs.apacheHttpd_2_4 pkgs.apacheHttpdPackages_2_4; apacheHttpdPackages_2_4 = dontRecurseIntoAttrs (apacheHttpdPackagesFor pkgs.apacheHttpd_2_4 pkgs.apacheHttpdPackages_2_4);
apacheHttpdPackages = apacheHttpdPackages_2_4; apacheHttpdPackages = apacheHttpdPackages_2_4;
appdaemon = callPackage ../servers/home-assistant/appdaemon.nix { }; appdaemon = callPackage ../servers/home-assistant/appdaemon.nix { };
@ -14393,9 +14401,9 @@ in
inherit (linuxPackages) kernel; inherit (linuxPackages) kernel;
}; };
fusePackages = callPackage ../os-specific/linux/fuse { fusePackages = dontRecurseIntoAttrs (callPackage ../os-specific/linux/fuse {
utillinux = utillinuxMinimal; utillinux = utillinuxMinimal;
}; });
fuse = lowPrio fusePackages.fuse_2; fuse = lowPrio fusePackages.fuse_2;
fuse3 = fusePackages.fuse_3; fuse3 = fusePackages.fuse_3;
fuse-common = hiPrio fusePackages.fuse_3.common; fuse-common = hiPrio fusePackages.fuse_3.common;
@ -14684,7 +14692,7 @@ in
nvidiabl = callPackage ../os-specific/linux/nvidiabl { }; nvidiabl = callPackage ../os-specific/linux/nvidiabl { };
nvidiaPackages = callPackage ../os-specific/linux/nvidia-x11 { }; nvidiaPackages = dontRecurseIntoAttrs (callPackage ../os-specific/linux/nvidia-x11 { });
nvidia_x11_legacy304 = nvidiaPackages.legacy_304; nvidia_x11_legacy304 = nvidiaPackages.legacy_304;
nvidia_x11_legacy340 = nvidiaPackages.legacy_340; nvidia_x11_legacy340 = nvidiaPackages.legacy_340;
@ -15884,12 +15892,12 @@ in
source-han-code-jp = callPackage ../data/fonts/source-han-code-jp { }; source-han-code-jp = callPackage ../data/fonts/source-han-code-jp { };
sourceHanSansPackages = callPackage ../data/fonts/source-han-sans { }; sourceHanSansPackages = dontRecurseIntoAttrs (callPackage ../data/fonts/source-han-sans { });
source-han-sans-japanese = sourceHanSansPackages.japanese; source-han-sans-japanese = sourceHanSansPackages.japanese;
source-han-sans-korean = sourceHanSansPackages.korean; source-han-sans-korean = sourceHanSansPackages.korean;
source-han-sans-simplified-chinese = sourceHanSansPackages.simplified-chinese; source-han-sans-simplified-chinese = sourceHanSansPackages.simplified-chinese;
source-han-sans-traditional-chinese = sourceHanSansPackages.traditional-chinese; source-han-sans-traditional-chinese = sourceHanSansPackages.traditional-chinese;
sourceHanSerifPackages = callPackage ../data/fonts/source-han-serif { }; sourceHanSerifPackages = dontRecurseIntoAttrs (callPackage ../data/fonts/source-han-serif { });
source-han-serif-japanese = sourceHanSerifPackages.japanese; source-han-serif-japanese = sourceHanSerifPackages.japanese;
source-han-serif-korean = sourceHanSerifPackages.korean; source-han-serif-korean = sourceHanSerifPackages.korean;
source-han-serif-simplified-chinese = sourceHanSerifPackages.simplified-chinese; source-han-serif-simplified-chinese = sourceHanSerifPackages.simplified-chinese;
@ -16095,7 +16103,7 @@ in
gconf = gnome2.GConf; gconf = gnome2.GConf;
}; };
atomPackages = callPackage ../applications/editors/atom { }; atomPackages = dontRecurseIntoAttrs (callPackage ../applications/editors/atom { });
inherit (atomPackages) atom atom-beta; inherit (atomPackages) atom atom-beta;
@ -16867,8 +16875,8 @@ in
cask = callPackage ../applications/editors/emacs-modes/cask { }; cask = callPackage ../applications/editors/emacs-modes/cask { };
}; };
emacs25Packages = emacsPackagesFor emacs25 pkgs.emacs25Packages; emacs25Packages = dontRecurseIntoAttrs (emacsPackagesFor emacs25 pkgs.emacs25Packages);
emacs26Packages = emacsPackagesFor emacs26 pkgs.emacs26Packages; emacs26Packages = dontRecurseIntoAttrs (emacsPackagesFor emacs26 pkgs.emacs26Packages);
emacsPackagesNgFor = emacs: import ./emacs-packages.nix { emacsPackagesNgFor = emacs: import ./emacs-packages.nix {
inherit lib newScope stdenv; inherit lib newScope stdenv;
@ -16893,9 +16901,10 @@ in
}; };
}; };
emacs25PackagesNg = emacsPackagesNgFor emacs25; emacs25PackagesNg = dontRecurseIntoAttrs (emacsPackagesNgFor emacs25);
emacs26PackagesNg = dontRecurseIntoAttrs (emacsPackagesNgFor emacs26);
emacs25WithPackages = emacs25PackagesNg.emacsWithPackages; emacs25WithPackages = emacs25PackagesNg.emacsWithPackages;
emacs26PackagesNg = emacsPackagesNgFor emacs26;
emacs26WithPackages = emacs26PackagesNg.emacsWithPackages; emacs26WithPackages = emacs26PackagesNg.emacsWithPackages;
emacsWithPackages = emacsPackagesNg.emacsWithPackages; emacsWithPackages = emacsPackagesNg.emacsWithPackages;
@ -19524,7 +19533,7 @@ in
taskserver = callPackage ../servers/misc/taskserver { }; taskserver = callPackage ../servers/misc/taskserver { };
tdesktopPackages = callPackage ../applications/networking/instant-messengers/telegram/tdesktop { }; tdesktopPackages = dontRecurseIntoAttrs (callPackage ../applications/networking/instant-messengers/telegram/tdesktop { });
tdesktop = tdesktopPackages.stable; tdesktop = tdesktopPackages.stable;
telegram-cli = callPackage ../applications/networking/instant-messengers/telegram/telegram-cli { }; telegram-cli = callPackage ../applications/networking/instant-messengers/telegram/telegram-cli { };
@ -19941,7 +19950,7 @@ in
weechat = wrapWeechat weechat-unwrapped { }; weechat = wrapWeechat weechat-unwrapped { };
weechatScripts = callPackage ../applications/networking/irc/weechat/scripts { }; weechatScripts = dontRecurseIntoAttrs (callPackage ../applications/networking/irc/weechat/scripts { });
westonLite = weston.override { westonLite = weston.override {
pango = null; pango = null;
@ -20991,7 +21000,7 @@ in
stockfish = callPackage ../games/stockfish { }; stockfish = callPackage ../games/stockfish { };
steamPackages = callPackage ../games/steam { }; steamPackages = dontRecurseIntoAttrs (callPackage ../games/steam { });
steam = steamPackages.steam-chrootenv; steam = steamPackages.steam-chrootenv;
@ -21096,7 +21105,7 @@ in
ue4demos = recurseIntoAttrs (callPackage ../games/ue4demos { }); ue4demos = recurseIntoAttrs (callPackage ../games/ue4demos { });
ut2004Packages = callPackage ../games/ut2004 { }; ut2004Packages = dontRecurseIntoAttrs (callPackage ../games/ut2004 { });
ut2004demo = res.ut2004Packages.ut2004 [ res.ut2004Packages.ut2004-demo ]; ut2004demo = res.ut2004Packages.ut2004 [ res.ut2004Packages.ut2004-demo ];
@ -21205,9 +21214,9 @@ in
keen4 = callPackage ../games/keen4 { }; keen4 = callPackage ../games/keen4 { };
zeroadPackages = callPackage ../games/0ad { zeroadPackages = dontRecurseIntoAttrs (callPackage ../games/0ad {
wxGTK = wxGTK30; wxGTK = wxGTK30;
}; });
zeroad = zeroadPackages.zeroad; zeroad = zeroadPackages.zeroad;