2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
sphinx,
|
|
|
|
pdf2svg,
|
|
|
|
texliveSmall,
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "sphinxcontrib-tikz";
|
2024-05-15 15:35:15 +00:00
|
|
|
version = "0.4.19";
|
2024-01-02 11:29:13 +00:00
|
|
|
format = "setuptools";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2024-05-15 15:35:15 +00:00
|
|
|
hash = "sha256-gen+bH4NvEbxnxr5HStisB1BqyKIS4n1VoHyAK4mXUk=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace sphinxcontrib/tikz.py \
|
2024-06-05 15:53:02 +00:00
|
|
|
--replace "config.latex_engine" "'${
|
|
|
|
texliveSmall.withPackages (
|
|
|
|
ps: with ps; [
|
|
|
|
standalone
|
|
|
|
pgfplots
|
|
|
|
]
|
|
|
|
)
|
|
|
|
}/bin/pdflatex'" \
|
2021-09-18 10:52:07 +00:00
|
|
|
--replace "system(['pdf2svg'" "system(['${pdf2svg}/bin/pdf2svg'"
|
|
|
|
'';
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
propagatedBuildInputs = [ sphinx ];
|
|
|
|
|
|
|
|
# no tests in package
|
|
|
|
doCheck = false;
|
|
|
|
|
2021-10-28 06:52:43 +00:00
|
|
|
pythonImportsCheck = [ "sphinxcontrib.tikz" ];
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
pythonNamespaces = [ "sphinxcontrib" ];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "TikZ extension for Sphinx";
|
|
|
|
homepage = "https://bitbucket.org/philexander/tikz";
|
2023-08-04 22:07:22 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.bsd3;
|
|
|
|
};
|
|
|
|
}
|