diff options
author | Michael Raskin <7c6f434c@mail.ru> | 2018-10-30 20:37:27 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-30 20:37:27 +0000 |
commit | b201817eb335d1b70882a794232e83789702fa96 (patch) | |
tree | dcf8ef8b64d2f36570b0c480f0156cc7794d4036 /pkgs/tools | |
parent | 628b6cc6795f7209717476a82a2a7b37df4e05f7 (diff) | |
parent | 20643a78073ecd95e960317c6b7488ba0febbf06 (diff) | |
download | nixlib-b201817eb335d1b70882a794232e83789702fa96.tar nixlib-b201817eb335d1b70882a794232e83789702fa96.tar.gz nixlib-b201817eb335d1b70882a794232e83789702fa96.tar.bz2 nixlib-b201817eb335d1b70882a794232e83789702fa96.tar.lz nixlib-b201817eb335d1b70882a794232e83789702fa96.tar.xz nixlib-b201817eb335d1b70882a794232e83789702fa96.tar.zst nixlib-b201817eb335d1b70882a794232e83789702fa96.zip |
Merge pull request #49416 from veprbl/pr/texlive_repstopdf_fix
texlive: provide repstopdf
Diffstat (limited to 'pkgs/tools')
-rw-r--r-- | pkgs/tools/typesetting/tex/texlive/combine.nix | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/pkgs/tools/typesetting/tex/texlive/combine.nix b/pkgs/tools/typesetting/tex/texlive/combine.nix index f76b71ced3cf..ea2926748198 100644 --- a/pkgs/tools/typesetting/tex/texlive/combine.nix +++ b/pkgs/tools/typesetting/tex/texlive/combine.nix @@ -218,9 +218,30 @@ in buildEnv { ln -sv "$(realpath $s)" "$out/bin/$tName" # wrapped below done ) + '' + + # A hacky way to provide repstopdf + # * Copy is done to have a correct "$0" so that epstopdf enables the restricted mode + # * ./bin/repstopdf needs to be a symlink to be processed by wrapBin + '' + if [[ -e ./bin/epstopdf ]]; then + cp $(realpath ./bin/epstopdf) ./share/texmf/scripts/repstopdf + ln -s "$out"/share/texmf/scripts/repstopdf ./bin/repstopdf + fi + '' + + # finish up the wrappers + '' rm "$out"/bin/*-sys wrapBin '' + + # Perform a small test to verify that the restricted mode get enabled when + # needed (detected by checking if it disallows --gscmd) + '' + if [[ -e ./bin/epstopdf ]]; then + echo "Testing restricted mode for {,r}epstopdf" + ! (epstopdf --gscmd echo /dev/null 2>&1 || true) | grep forbidden + (repstopdf --gscmd echo /dev/null 2>&1 || true) | grep forbidden + fi + '' + # TODO: a context trigger https://www.preining.info/blog/2015/06/debian-tex-live-2015-the-new-layout/ # http://wiki.contextgarden.net/ConTeXt_Standalone#Unix-like_platforms_.28Linux.2FMacOS_X.2FFreeBSD.2FSolaris.29 |