Merge pull request #57583 from costrouc/python-init-sphinxcontrib-tikz
pythonPackages.sphinxcontrib-tikz: init at 0.4.6
This commit is contained in:
commit
2e8fc97dbf
|
@ -0,0 +1,22 @@
|
|||
diff --git a/sphinxcontrib/tikz.py b/sphinxcontrib/tikz.py
|
||||
index ee21113..a4f4589 100644
|
||||
--- a/sphinxcontrib/tikz.py
|
||||
+++ b/sphinxcontrib/tikz.py
|
||||
@@ -242,7 +242,7 @@ def render_tikz(self, node, libs='', stringsubst=False):
|
||||
tf.write(latex)
|
||||
tf.close()
|
||||
|
||||
- system([self.builder.config.latex_engine, '--interaction=nonstopmode',
|
||||
+ system(['@texLive@/bin/pdflatex', '--interaction=nonstopmode',
|
||||
'tikz-%s.tex' % shasum],
|
||||
self.builder)
|
||||
|
||||
@@ -281,7 +281,7 @@ def render_tikz(self, node, libs='', stringsubst=False):
|
||||
'-sOutputFile=%s' % outfn, '-r' + resolution + 'x' + resolution,
|
||||
'-f', 'tikz-%s.pdf' % shasum], self.builder)
|
||||
elif self.builder.config.tikz_proc_suite == "pdf2svg":
|
||||
- system(['pdf2svg', 'tikz-%s.pdf' % shasum, outfn], self.builder)
|
||||
+ system(['@pdf2svg@/bin/pdf2svg', 'tikz-%s.pdf' % shasum, outfn], self.builder)
|
||||
else:
|
||||
self.builder._tikz_warned = True
|
||||
raise TikzExtError('Error (tikz extension): Invalid configuration '
|
|
@ -0,0 +1,38 @@
|
|||
{ lib
|
||||
, substituteAll
|
||||
, buildPythonPackage
|
||||
, fetchPypi
|
||||
, sphinx
|
||||
, pdf2svg
|
||||
, texLive
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "sphinxcontrib-tikz";
|
||||
version = "0.4.6";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "4f362b11e3c2bd17d5f0f07fec03917c16fc5bbcda6fe31ee137c547ed6b03a3";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(substituteAll {
|
||||
src = ./binary-paths.patch;
|
||||
inherit texLive pdf2svg;
|
||||
})
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [ sphinx ];
|
||||
|
||||
# no tests in package
|
||||
doCheck = false;
|
||||
|
||||
meta = with lib; {
|
||||
description = "TikZ extension for Sphinx";
|
||||
homepage = https://bitbucket.org/philexander/tikz;
|
||||
maintainers = with maintainers; [ costrouc ];
|
||||
license = licenses.bsd3;
|
||||
};
|
||||
|
||||
}
|
|
@ -5794,6 +5794,10 @@ in {
|
|||
|
||||
sphinxcontrib-spelling = callPackage ../development/python-modules/sphinxcontrib-spelling { };
|
||||
|
||||
sphinxcontrib-tikz = callPackage ../development/python-modules/sphinxcontrib-tikz {
|
||||
texLive = pkgs.texlive.combine { inherit (pkgs.texlive) scheme-small standalone pgfplots; };
|
||||
};
|
||||
|
||||
sphinx_pypi_upload = callPackage ../development/python-modules/sphinx_pypi_upload { };
|
||||
|
||||
Pweave = callPackage ../development/python-modules/pweave { };
|
||||
|
|
Loading…
Reference in New Issue