Skip to content

Commit b3135a5

Browse files
committed
Fix temporary configuration
1 parent 8ff06d6 commit b3135a5

File tree

1 file changed

+30
-26
lines changed

1 file changed

+30
-26
lines changed

flake.nix

Lines changed: 30 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
};
4949
nixpkgsFor' = system: import nixpkgs { inherit system; };
5050

51-
haskellModules = [
51+
haskellModules = system: [
5252
({ pkgs, ... }:
5353
{
5454
packages = {
@@ -63,28 +63,32 @@
6363
};
6464
}
6565
)
66-
({ config, pkgs, system, ... }: {
67-
packages.plutip-core.components.tests.plutip-tests = {
68-
pkgconfig = [ [ pkgs.makeWrapper ] ];
69-
postInstall = with pkgs; ''
70-
wrapProgram $out/bin/plutip-tests \
71-
--prefix PATH : "${lib.makeBinPath [
72-
cardano-node.packages.x86_64-darwin.cardano-node
73-
cardano-node.packages.x86_64-darwin.cardano-cli
74-
]}"
75-
'';
76-
};
77-
packages.plutip-core.components.exes.local-cluster = {
78-
pkgconfig = [ [ pkgs.makeWrapper ] ];
79-
postInstall = with pkgs; ''
80-
wrapProgram $out/bin/local-cluster \
81-
--prefix PATH : "${lib.makeBinPath [
82-
cardano-node.packages.x86_64-darwin.cardano-node
83-
cardano-node.packages.x86_64-darwin.cardano-cli
84-
]}"
85-
'';
86-
};
87-
})
66+
({ config, pkgs, ... }:
67+
let
68+
nodeExes = cardano-node.packages.${system};
69+
in
70+
{
71+
packages.plutip-core.components.tests.plutip-tests = {
72+
pkgconfig = [ [ pkgs.makeWrapper ] ];
73+
postInstall = with pkgs; ''
74+
wrapProgram $out/bin/plutip-tests \
75+
--prefix PATH : "${lib.makeBinPath [
76+
nodeExes.cardano-node
77+
nodeExes.cardano-cli
78+
]}"
79+
'';
80+
};
81+
packages.plutip-core.components.exes.local-cluster = {
82+
pkgconfig = [ [ pkgs.makeWrapper ] ];
83+
postInstall = with pkgs; ''
84+
wrapProgram $out/bin/local-cluster \
85+
--prefix PATH : "${lib.makeBinPath [
86+
nodeExes.cardano-node
87+
nodeExes.cardano-cli
88+
]}"
89+
'';
90+
};
91+
})
8892
];
8993

9094
projectFor = system:
@@ -124,12 +128,10 @@
124128
];
125129
};
126130

127-
modules = haskellModules;
131+
modules = haskellModules system;
128132
};
129133
in
130134
{
131-
inherit haskellModules;
132-
133135
project = perSystem projectFor;
134136
flake = perSystem (system: (projectFor system).flake { });
135137

@@ -183,6 +185,8 @@
183185
'';
184186
});
185187

188+
haskellModules = perSystem haskellModules;
189+
186190
# Instruction for the Hercules CI to build on x86_64-linux only, to avoid errors about systems without agents.
187191
herculesCI.ciSystems = [ "x86_64-linux" ];
188192
};

0 commit comments

Comments
 (0)