anchor.diff:      aafigure_path="$(toPythonPath ${aafigure})"
       sed -i "/^import.*sys/asys.path.append(\"$pth_loader_path\"); sys.path.append(\"$aafigure_path\"); import sitecustomize" \
           "$out/etc/asciidoc/filters/aafigure/aafig2img.py"
  +  '' + optionalString enableDeckjsBackend ''
  +    echo "Extracting deckjs backend"
  +    unzip -d "$out/etc/asciidoc/backends/deckjs" "${deckjsBackendSrc}"
     '' + ''
       for n in $(find "$out" . -name \*.py); do
         sed -i -e "s,^#![[:space:]]*/usr/bin/env python,#!${python}/bin/python,g" "$n"
  
positive.code:     sha256 = "1hq2s30dvmv5dqvj0xm1qwdwafhgm9w1iyr0lr0c40cyk8h00j8j";
    };
  
  in
  
  stdenv.mkDerivation rec {
  
negative.code: { fetchurl, stdenv, python
  , unzip ? null
  # filters
  , enableDitaaFilter ? false, jre ? null
  , enableMscgenFilter ? false, mscgen ? null
  , enableDiagFilter ? false, blockdiag ? null, seqdiag ? null, actdiag ? null, nwdiag ? null
  , enableQrcodeFilter ? false, qrencode ? null
  , enableMatplotlibFilter ? false, matplotlib ? null, numpy ? null
  , enableAafigureFilter ? false, aafigure ? null, recursivePthLoader ? null
  # backends
  , enableDeckjsBackend ? false
  }:
  
  # filters
  assert (enableDitaaFilter || enableMscgenFilter || enableDiagFilter || enableQrcodeFilter || enableAafigureFilter) -> unzip != null;
  assert enableDitaaFilter -> jre != null;
  assert enableMscgenFilter -> mscgen != null;
  assert enableDiagFilter -> blockdiag != null && seqdiag != null && actdiag != null && nwdiag != null;
  assert enableMatplotlibFilter -> matplotlib != null && numpy != null;
  assert enableAafigureFilter -> aafigure != null && recursivePthLoader != null;
  # backends
  assert enableDeckjsBackend -> unzip != null;
  
  let
  
    #
    # filters
    #
  
    ditaaFilterSrc = fetchurl {
      url = "https://asciidoc-ditaa-filter.googlecode.com/files/ditaa-filter-1.1.zip";
      sha256 = "0p7hm2a1xywx982ia3vg4c0lam5sz0xknsc10i2a5vswy026naf6";
  