Skip to content

Commit 6ca7e7e

Browse files
authored
Merge pull request #1133 from mirage/fix-flakes
Fix flakes build
2 parents a1b3a4e + fd21658 commit 6ca7e7e

File tree

2 files changed

+32
-29
lines changed

2 files changed

+32
-29
lines changed

flake.lock

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

flake.nix

Lines changed: 25 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -7,32 +7,35 @@
77
outputs = { self, nixpkgs, flake-utils }:
88
flake-utils.lib.eachDefaultSystem (system:
99
let
10-
pkgs = (import nixpkgs {
11-
inherit system;
12-
overlays = [
13-
(final: prev: {
14-
ocamlPackages = prev.ocamlPackages.overrideScope' (oself: osuper: {
15-
ctypes-foreign = osuper.ctypes-foreign.overrideAttrs (_: { doCheck = false; });
16-
ctypes = osuper.ctypes.overrideAttrs (_: { doCheck = false; });
17-
mdx = osuper.mdx.override {
18-
# workaround for:
19-
# https://github.com/NixOS/nixpkgs/pull/241476/commits/1ed74f3536d29e5635d7f47a1d7b82a89f5a8077
20-
logs = oself.logs;
21-
};
22-
});
23-
})
24-
];
10+
pkgs = import nixpkgs { inherit system; };
11+
ocamlPackages = pkgs.ocaml-ng.ocamlPackages_5_4.overrideScope (oself: osuper: {
12+
ctypes-foreign = osuper.ctypes-foreign.overrideAttrs (_: { doCheck = false; });
13+
ctypes = osuper.ctypes.overrideAttrs (_: { doCheck = false; });
14+
mdx = (osuper.mdx.override {
15+
# workaround for:
16+
# https://github.com/NixOS/nixpkgs/pull/241476/commits/1ed74f3536d29e5635d7f47a1d7b82a89f5a8077
17+
logs = oself.logs;
18+
}).overrideAttrs (_: { doCheck = false; });
19+
cmdliner = osuper.cmdliner.overrideAttrs (old: rec {
20+
version = "2.1.0";
21+
src = pkgs.fetchFromGitHub {
22+
owner = "dbuenzli";
23+
repo = "cmdliner";
24+
rev = "v${version}";
25+
sha256 = "sha256-ebe5I77zEKoehJ55ZszV0dQP4ZDfVpGXqDsEb2qEE24=";
26+
};
27+
});
2528
});
26-
inherit (pkgs.ocamlPackages) buildDunePackage;
29+
inherit (ocamlPackages) buildDunePackage;
2730
pkg = attrs: buildDunePackage ({
2831
version = "n/a";
2932
src = ./. ;
3033
duneVersion = "3";
3134
doCheck = true;
3235
} // attrs);
33-
ocamlformat = pkgs.ocamlformat_0_26_2;
36+
ocamlformat = pkgs.ocamlformat_0_27_0;
3437
in
35-
with pkgs.ocamlPackages; rec {
38+
with ocamlPackages; rec {
3639
packages = rec {
3740
default = http;
3841
http = pkg {
@@ -108,7 +111,7 @@
108111
checkInputs = [
109112
alcotest eio mdx ppx_here
110113
tls-eio
111-
mirage-crypto-rng-eio
114+
mirage-crypto-rng
112115
];
113116
propagatedBuildInputs = [ cohttp eio logs uri fmt ptime http ];
114117
};
@@ -129,14 +132,14 @@
129132
};
130133
devShells.default = pkgs.mkShell {
131134
inputsFrom = pkgs.lib.attrValues packages;
132-
buildInputs = [ ocamlformat ] ++ (with pkgs.ocamlPackages; [
135+
buildInputs = [ ocamlformat ] ++ (with ocamlPackages; [
133136
ocaml-lsp
134137
]);
135138
};
136139
devShells.eio = pkgs.mkShell {
137140
inputsFrom = [ cohttp-eio ];
138-
buildInputs = [ ocamlformat ] ++ (with pkgs; [
139-
ocamlPackages.ocaml-lsp gmp libev nmap curl
141+
buildInputs = [ ocamlformat ocamlPackages.ocaml-lsp ] ++ (with pkgs; [
142+
gmp libev nmap curl
140143
]);
141144
};
142145
});

0 commit comments

Comments
 (0)