@@ -10710,14 +10710,16 @@ let
1071010710 url = "mirror://cpan/authors/id/B/BR/BRMILLER/LaTeXML-0.8.4.tar.gz";
1071110711 sha256 = "92599b45fb587ac14b2ba9cc84b85d9ddc2deaf1cbdc2e89e7a6559e1fbb34cc";
1071210712 };
10713− propagatedBuildInputs = [ shortenPerlShebang ArchiveZip DBFile FileWhich IOString ImageSize JSONXS LWP ParseRecDescent PodParser TextUnidecode XMLLibXSLT ];
10713+ propagatedBuildInputs = [ ArchiveZip DBFile FileWhich IOString ImageSize JSONXS LWP ParseRecDescent PodParser TextUnidecode XMLLibXSLT ];
1071410714 doCheck = false; # epub test fails
10715− postInstall = ''
10716− shortenPerlShebang $out/bin/latexml
10717− shortenPerlShebang $out/bin/latexmlc
10718− shortenPerlShebang $out/bin/latexmlfind
10719− shortenPerlShebang $out/bin/latexmlmath
10720− shortenPerlShebang $out/bin/latexmlpost
10715+ nativeBuildInputs = stdenv.lib.optional stdenv.isDarwin shortenPerlShebang;
10716+ # shebangs need to be patched before executables are copied to $out
10717+ preBuild = ''
10718+ patchShebangs bin/
10719+ '' + stdenv.lib.optionalString stdenv.isDarwin ''
10720+ for file in bin/*; do
10721+ shortenPerlShebang "$file"
10722+ done
1072110723 '';
1072210724 meta = {
1072310725 description = "Transforms TeX and LaTeX into XML/HTML/MathML";