anchor.diff:      # woff extra
       brotlipy
       zopfli
  -    # unicode extra
  -    unicodedata2
       # interpolatable extra
       scipy
       munkres
  
positive.code: , matplotlib
  , reportlab
  , sphinx
  , pytest
  , pytest-randomly
  , glibcLocales
  }:
  
  buildPythonPackage rec {
    pname = "fonttools";
    version = "4.21.1";
    disabled = pythonOlder "3.6";
  
    src = fetchFromGitHub {
      owner  = pname;
      repo   = pname;
      rev    = version;
      sha256 = "1x9qrg6ppqhm5214ymwvn0r34qdz8pqvyxd0sj7rkp06wa757z2i";
    };
  
    # all dependencies are optional, but
    # we run the checks with them
    checkInputs = [
      pytest
      pytest-randomly
      glibcLocales
      # etree extra
      lxml
      # ufo extra
  
negative.code:     # pens
      reportlab
      sphinx
    ] ++ lib.optionals (pythonOlder "3.9") [
      # unicode extra
      unicodedata2
    ];
  
    preCheck = ''
      # tests want to execute the "fonttools" executable from $PATH
      export PATH="$out/bin:$PATH"
    '';
  
    # Timestamp tests have timing issues probably related
    # to our file timestamp normalization
    disabledTests = [
      "test_recalc_timestamp_ttf"
      "test_recalc_timestamp_otf"
      "test_ttcompile_timestamp_calcs"
    ];
  
    meta = with lib; {
      homepage = "https://github.com/fonttools/fonttools";
  