nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 ocaml,
6 findlib,
7}:
8
9stdenv.mkDerivation (finalAttrs: {
10 version = "2.8.1";
11 pname = "ocaml${ocaml.version}-camlpdf";
12
13 src = fetchFromGitHub {
14 owner = "johnwhitington";
15 repo = "camlpdf";
16 tag = "v${finalAttrs.version}";
17 hash = "sha256-ZExQtcFBPiS7c6v+WEjZYQ6zXtqRTNLV0hYzYSB/eLE=";
18 };
19
20 nativeBuildInputs = [
21 ocaml
22 findlib
23 ];
24
25 strictDeps = true;
26
27 preInstall = ''
28 mkdir -p $out/lib/ocaml/${ocaml.version}/site-lib/stublibs
29 '';
30
31 meta = {
32 description = "OCaml library for reading, writing and modifying PDF files";
33 homepage = "https://github.com/johnwhitington/camlpdf";
34 license = lib.licenses.lgpl21Plus;
35 maintainers = with lib.maintainers; [ vbgl ];
36 broken = lib.versionOlder ocaml.version "4.10";
37 };
38})