From 5277e7def7b167021ae49a3d101926b40b98e745 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Sat, 8 Jul 2023 16:02:11 -0400 Subject: flake nix build dub, set HOME, dub >= 1.31.0 fix - fixes dub >= 1.31.0 build failure, attempted to build in /homeless-shelter --- flake.nix | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'flake.nix') diff --git a/flake.nix b/flake.nix index 336fb0e..8a411b3 100644 --- a/flake.nix +++ b/flake.nix @@ -61,6 +61,9 @@ inherit devEnv; buildInputs = [sqlite]; nativeBuildInputs = [dub ldc gnumake]; + preBuild = '' + export HOME=$(pwd) + ''; buildPhase = '' runHook preBuild for DC_ in dmd ldmd2 ldc2 gdc gdmd; do @@ -87,6 +90,9 @@ inherit devEnv; buildInputs = [sqlite]; nativeBuildInputs = [dub dmd gnumake]; + preBuild = '' + export HOME=$(pwd) + ''; buildPhase = '' runHook preBuild dub build --cache=local --compiler=$(type -P dmd) --build=dmd --combined --skip-registry=all @@ -106,6 +112,9 @@ inherit devEnv; buildInputs = [sqlite]; nativeBuildInputs = [dub ldc gnumake]; + preBuild = '' + export HOME=$(pwd) + ''; buildPhase = '' runHook preBuild dub build --cache=local --compiler=$(type -P ldc2) --build=ldc2 --combined --skip-registry=all @@ -125,6 +134,9 @@ inherit devEnv; buildInputs = with pkgs; [sqlite]; nativeBuildInputs = with pkgs; [dub ldc gnumake]; + preBuild = '' + export HOME=$(pwd) + ''; buildPhase = '' runHook preBuild dub build --cache=local --compiler=$(type -P ldc2) --build=ldc2 --combined --skip-registry=all -- cgit v1.2.3