Skip to content

Commit 3733b9f

Browse files
committed
git fix from haskell.nix
1 parent 235669d commit 3733b9f

File tree

4 files changed

+297
-169
lines changed

4 files changed

+297
-169
lines changed

flake.lock

Lines changed: 10 additions & 157 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/call-cabal-project-to-nix.nix

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,9 +267,14 @@ let
267267
sourceRepos = sourceReposBuild;
268268
inherit (repoResult) repos extra-hackages;
269269
makeFixedProjectFile = ''
270+
HOME=$(mktemp -d)
270271
cp -f ${evalPackages.writeText "cabal.project" sourceRepoFixedProjectFile} ./cabal.project
271272
chmod +w -R ./cabal.project
272-
'';
273+
'' + pkgs.lib.strings.concatStrings (
274+
map (f: ''
275+
git config --global --add safe.directory ${f.location}/.git
276+
'') sourceReposEval
277+
);
273278
# This will be used to replace refernces to the minimal git repos with just the index
274279
# of the repo. The index will be used in lib/import-and-filter-project.nix to
275280
# lookup the correct repository in `sourceReposBuild`. This avoids having

modules/component-driver.nix

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ in
2424

2525
options.reinstallableLibGhc = lib.mkOption {
2626
type = lib.types.bool;
27-
default = true;
27+
default = false;
2828
description = "Is lib:ghc reinstallable?";
2929
};
3030
options.setup-depends = lib.mkOption {
@@ -58,10 +58,11 @@ in
5858
"array"
5959
"ghc-boot-th" "template-haskell"
6060
"ghc-boot" "ghc-platform" "ghc-internal" "ghc-heap" "ghc"
61-
"system-cxx-std-lib" "pretty" "deepseq" "ghc-bignum"
61+
"system-cxx-std-lib" "pretty" "deepseq" "ghc-bignum" "os-string"
6262

6363
# ghcjs custom packages
64-
"ghcjs-prim" "ghcjs-th"
64+
"ghcjs-prim" "ghcjs-th" "bytestring" "exception" "mtl" "stm" "transformers"
65+
"file-io" "directory" "process"
6566
];
6667

6768
options.bootPkgs = lib.mkOption {
@@ -70,14 +71,9 @@ in
7071

7172
config.bootPkgs = [
7273
"rts" "ghc-boot-th" "ghc-boot" "ghc-heap" "ghci"
73-
"ghcjs-prim"
74-
] ++ lib.optional (!config.reinstallableLibGhc) "ghc"
75-
++ lib.optionals (
76-
!__elem config.compiler.nix-name ["ghc865" "ghc881" "ghc882" "ghc883" "ghc884" "ghc8101" "ghc8102" "ghc8103" "ghc8104" "ghc8105" "ghc8106" "ghc8107"]) [
77-
"ghc-bignum" ]
78-
++ lib.optionals (
79-
!__elem config.compiler.nix-name ["ghc865" "ghc881" "ghc882" "ghc883" "ghc884" "ghc8101" "ghc8102" "ghc8103" "ghc8104" "ghc8105" "ghc8106" "ghc8107" "ghc901" "ghc902"]) [
80-
"system-cxx-std-lib" ];
74+
"ghcjs-prim" "ghc-bignum" "system-cxx-std-lib"
75+
"ghc-platform"
76+
];
8177

8278
options.hsPkgs = lib.mkOption {
8379
type = lib.types.unspecified;

0 commit comments

Comments
 (0)