blob: a095bd41cbefe5fe8ba127a095a8203f35fb5bb1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
{
inputs = {
flake-utils.url = "github:numtide/flake-utils";
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
ocaml.url = "github:nix-ocaml/nix-overlays";
ocaml.inputs.nixpkgs.follows = "nixpkgs";
# it's broken wtf
# lsp.url = "github:ocaml/ocaml-lsp";
# lsp.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = {
self,
nixpkgs,
ocaml,
flake-utils,
}:
flake-utils.lib.eachDefaultSystem (system: let
pkgs = import nixpkgs {
inherit system;
overlays = [
ocaml.overlays.default
(final: prev: {
# This ensures we consistently use one version of ocaml packages
ocamlPackages = prev.ocaml-ng.ocamlPackages_5_3;
ocaml = prev.ocaml-ng.ocamlPackages_5_3.ocaml;
})
];
};
in {
devShells.default = pkgs.mkShell rec {
buildInputs =
nativeBuildInputs
++ (with pkgs.ocamlPackages; [utop]);
nativeBuildInputs = with pkgs.ocamlPackages; [
pkgs.zig_0_14
pkgs.sqlite
pkgs.dune_3
pkgs.ocaml
(pkgs.python312.withPackages (py: [py.requests]))
pkgs.opam
findlib
ocamlformat
#
zarith
cmdliner
logs
alcotest
qcheck
qcheck-alcotest
landmarks
ctypes
ctypes-foreign
#
ocaml-lsp
eio_main
lmdb
domainslib
# http server
piaf
];
};
});
}
|