anchor.diff: -{ stdenv, fetchurl, ocaml, findlib, opam, gg, uutf, otfm, js_of_ocaml,
  +{ stdenv, fetchurl, ocaml, findlib, opam, topkg
  +, uchar, result, gg, uutf, otfm, js_of_ocaml,
     pdfBackend ? true, # depends on uutf and otfm
     htmlcBackend ? true # depends on js_of_ocaml
   }:
   
   let
  -  inherit (stdenv.lib) getVersion optionals versionAtLeast;
  +  inherit (stdenv.lib) optionals versionAtLeast;
   
     pname = "vg";
  -  version = "0.8.1";
  +  version = "0.9.0";
     webpage = "http://erratique.ch/software/${pname}";
  +  sob = b: if b then "true" else "false";
   in
   
  -assert versionAtLeast (getVersion ocaml) "4.01.0";
  +assert versionAtLeast ocaml.version "4.02.0";
   
   stdenv.mkDerivation rec {
   
  
positive.code: 
    unpackCmd = "tar xjf $src";
  
    buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true"
                 + (if pdfBackend then " uutf=true otfm=true"
                                  else " uutf=false otfm=false")
                 + (if htmlcBackend then " jsoo=true"
                                    else " jsoo=false");
  
    installPhase = ''
      opam-installer --script --prefix=$out ${pname}.install | sh
      ln -s $out/lib/${pname} $out/lib/ocaml/${getVersion ocaml}/site-lib/${pname}
    '';
  
    meta = with stdenv.lib; {
      description = "Declarative 2D vector graphics for OCaml";
  
negative.code: 
    src = fetchurl {
      url = "${webpage}/releases/${pname}-${version}.tbz";
      sha256 = "1czd2fq85hy24w5pllarsq4pvbx9rda5zdikxfxdng8s9kff2h3f";
    };
  
    buildInputs = [ ocaml findlib opam topkg ];
  
    propagatedBuildInputs = [ uchar result gg ]
                            ++ optionals pdfBackend [ uutf otfm ]
                            ++ optionals htmlcBackend [ js_of_ocaml ];
  
  