diff --git a/lib/flake-lib.nix b/lib/flake-lib.nix index 146af196..bbe111cb 100644 --- a/lib/flake-lib.nix +++ b/lib/flake-lib.nix @@ -7,9 +7,10 @@ inputs: rec { }: import nixpkgs { inherit system; + overlays = [inputs.self.overlays.build-failures]; config = { - allowUnfree = true; inherit cudaSupport; + allowUnfree = true; }; }; diff --git a/outputs.nix b/outputs.nix index cb59b001..97077e91 100644 --- a/outputs.nix +++ b/outputs.nix @@ -135,11 +135,11 @@ legacyPackages = perSystem (pkgs: - import ./legacyPackages {inherit mkVersion pkgs inputs;}); + import ./legacyPackages {inherit inputs mkVersion pkgs;}); packages = perSystem (pkgs: - import ./packages {inherit self pkgs mkVersion inputs;}); + import ./packages {inherit inputs mkVersion pkgs;}); overlays = import ./overlays {}; diff --git a/overlays/build-failures/default.nix b/overlays/build-failures/default.nix new file mode 100644 index 00000000..7e51b64f --- /dev/null +++ b/overlays/build-failures/default.nix @@ -0,0 +1,10 @@ +final: prev: { + # FIXME: dmd doesn't build on latest nixos-unstable. make issue? + dmd = prev.dmd.overrideAttrs (o: { + postPatch = + o.postPatch + + '' + rm dmd/compiler/test/fail_compilation/needspkgmod.d + ''; + }); +} diff --git a/overlays/default.nix b/overlays/default.nix index ac9abc78..47acc1ef 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -1,3 +1,4 @@ {...}: { + build-failures = import ./build-failures; xdg-desktop-portal-kde = import ./xdg-desktop-portal-kde; } diff --git a/packages/trash-d/default.nix b/packages/trash-d/default.nix index 06b4eba9..fa16fb9d 100644 --- a/packages/trash-d/default.nix +++ b/packages/trash-d/default.nix @@ -19,16 +19,7 @@ in buildInputs = [ dub ronn - - # FIXME: dmd doesn't build on latest nixos-unstable. make issue? - # FIXME: `config.nixpkgs.overlays` don't seem to apply on `self.packages` or `self.legacyPackages` - (dmd.overrideAttrs (o: { - postPatch = - o.postPatch - + '' - rm dmd/compiler/test/fail_compilation/needspkgmod.d - ''; - })) + dmd ]; buildPhase = ''