on fd39d56 help sign in
haskell.nix/modules/component-driver.nix
18 lines 520 B history raw
1{ config, pkgs, lib, haskellLib, ... }:
2let
3 # TODO: this pkgs is the adjusted pkgs, but pkgs.pkgs is unadjusted
4 new-builder = haskellLib.weakCallPackage pkgs ../builder {
5 inherit haskellLib;
6 ghc = config.ghc.package;
7 };
8in
11 options.hsPkgs = lib.mkOption {
12 type = lib.types.unspecified;
13 };
15 config.hsPkgs = { buildPackages = config.hsPkgs; }
16 // lib.mapAttrs (_: _: null) config.compiler.packages
17 // lib.mapAttrs (_: pkg: if pkg == null then null else new-builder pkg) config.packages;