2014-12-31 11:21:55 +00:00
|
|
|
{ stdenv, fetchgit, ocaml, findlib, ncurses }:
|
2014-11-16 08:42:55 +00:00
|
|
|
|
2014-12-31 11:21:55 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2017-01-20 06:36:44 +00:00
|
|
|
version = "2.2.1";
|
|
|
|
name = "ocaml${ocaml.version}-camlpdf-${version}";
|
2014-11-16 08:42:55 +00:00
|
|
|
src = fetchgit {
|
|
|
|
url = https://github.com/johnwhitington/camlpdf.git;
|
2014-12-31 11:21:55 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2017-01-20 06:36:44 +00:00
|
|
|
sha256 = "0wa4rw8ccpb8xprslg88hbk352bi8bia4iffc22y55gkjr60f8gj";
|
2014-11-16 08:42:55 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ ocaml findlib ncurses ];
|
|
|
|
|
|
|
|
# Version number in META file is wrong
|
|
|
|
patchPhase = ''
|
|
|
|
patch -p 0 META <<EOF
|
|
|
|
3c3
|
|
|
|
< version="1.7.1"
|
|
|
|
---
|
2014-12-31 11:21:55 +00:00
|
|
|
> version="${version}"
|
2014-11-16 08:42:55 +00:00
|
|
|
EOF
|
|
|
|
'';
|
|
|
|
|
|
|
|
createFindlibDestdir = true;
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "An OCaml library for reading, writing and modifying PDF files";
|
|
|
|
homepage = https://github.com/johnwhitington/camlpdf;
|
|
|
|
license = licenses.lgpl21Plus;
|
|
|
|
maintainers = with maintainers; [vbgl];
|
|
|
|
};
|
|
|
|
}
|