2020-12-29 01:48:13 -08:00
|
|
|
{ lib, buildPythonPackage, fetchPypi, isPy3k, python3, xvfb_run, stdenv
|
|
|
|
, wrapGAppsHook, gobject-introspection, pygobject3, graphviz, gtk3, numpy }:
|
2018-02-19 14:25:14 -08:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "xdot";
|
2020-11-29 06:04:46 -08:00
|
|
|
version = "1.2";
|
2018-02-19 14:25:14 -08:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-11-29 06:04:46 -08:00
|
|
|
sha256 = "3df91e6c671869bd2a6b2a8883fa3476dbe2ba763bd2a7646cf848a9eba71b70";
|
2018-02-19 14:25:14 -08:00
|
|
|
};
|
|
|
|
|
2018-04-22 00:55:10 -07:00
|
|
|
disabled = !isPy3k;
|
2018-02-19 14:25:14 -08:00
|
|
|
nativeBuildInputs = [ wrapGAppsHook ];
|
2020-12-29 01:48:13 -08:00
|
|
|
propagatedBuildInputs = [ gobject-introspection pygobject3 graphviz gtk3 numpy ];
|
|
|
|
checkInputs = [ xvfb_run ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
xvfb-run -s '-screen 0 800x600x24' ${python3.interpreter} nix_run_setup test
|
|
|
|
'';
|
|
|
|
|
|
|
|
# https://github.com/NixOS/nixpkgs/pull/107872#issuecomment-752175866
|
2021-01-09 15:19:07 -08:00
|
|
|
# cannot import name '_gi' from partially initialized module 'gi' (most likely due to a circular import)
|
|
|
|
doCheck = false;
|
2018-02-19 14:25:14 -08:00
|
|
|
|
|
|
|
meta = with lib; {
|
2020-10-25 21:08:40 -07:00
|
|
|
description = "An interactive viewer for graphs written in Graphviz's dot";
|
2020-03-31 18:11:51 -07:00
|
|
|
homepage = "https://github.com/jrfonseca/xdot.py";
|
2018-02-19 14:25:14 -08:00
|
|
|
license = licenses.lgpl3Plus;
|
|
|
|
};
|
|
|
|
}
|