nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 stdenv,
3 lib,
4 fetchFromGitHub,
5 ocaml,
6 findlib,
7 astring,
8 pprint,
9}:
10
11stdenv.mkDerivation rec {
12 pname = "ocaml${ocaml.version}-ocp-ocamlres";
13 version = "0.4";
14 src = fetchFromGitHub {
15 owner = "OCamlPro";
16 repo = "ocp-ocamlres";
17 rev = "v${version}";
18 sha256 = "0smfwrj8qhzknhzawygxi0vgl2af4vyi652fkma59rzjpvscqrnn";
19 };
20
21 nativeBuildInputs = [
22 ocaml
23 findlib
24 ];
25 buildInputs = [
26 astring
27 pprint
28 ];
29
30 strictDeps = true;
31
32 createFindlibDestdir = true;
33
34 installFlags = [ "BINDIR=$(out)/bin" ];
35 preInstall = "mkdir -p $out/bin";
36
37 meta = {
38 description = "Simple tool and library to embed files and directories inside OCaml executables";
39 homepage = "https://www.typerex.org/ocp-ocamlres.html";
40 license = lib.licenses.lgpl3Plus;
41 maintainers = [ lib.maintainers.vbgl ];
42 mainProgram = "ocp-ocamlres";
43 inherit (ocaml.meta) platforms;
44 broken = lib.versionOlder ocaml.version "4.02";
45 };
46}