Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 21.05 47 lines 996 B view raw
1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, substituteAll 5, graphviz 6, makeFontsConf 7, freefont_ttf 8, mock 9, pytestCheckHook 10, pytest-mock 11, pytestcov 12}: 13 14buildPythonPackage rec { 15 pname = "graphviz"; 16 version = "0.16"; 17 18 # patch does not apply to PyPI tarball due to different line endings 19 src = fetchFromGitHub { 20 owner = "xflr6"; 21 repo = "graphviz"; 22 rev = version; 23 sha256 = "147vi60mi57z623lhllwwzczzicv2iwj1yrmllj5xx5788i73j6g"; 24 }; 25 26 patches = [ 27 (substituteAll { 28 src = ./hardcode-graphviz-path.patch; 29 inherit graphviz; 30 }) 31 ]; 32 33 # Fontconfig error: Cannot load default config file 34 FONTCONFIG_FILE = makeFontsConf { 35 fontDirectories = [ freefont_ttf ]; 36 }; 37 38 checkInputs = [ mock pytestCheckHook pytest-mock pytestcov ]; 39 40 meta = with lib; { 41 description = "Simple Python interface for Graphviz"; 42 homepage = "https://github.com/xflr6/graphviz"; 43 license = licenses.mit; 44 maintainers = with maintainers; [ dotlambda ]; 45 }; 46 47}