summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/latexconfig
diff options
context:
space:
mode:
authorManuel Pégourié-Gonnard <mpg@elzevir.fr>2010-06-14 11:22:59 +0000
committerManuel Pégourié-Gonnard <mpg@elzevir.fr>2010-06-14 11:22:59 +0000
commit65e872afda15da66eaaf7efe40b3f57045e08b9b (patch)
tree91ae07412e11318cef785ea29c38860b012c2631 /Master/texmf-dist/tex/latex/latexconfig
parent834e7463dc799167a37e34364193444ef2c18e8d (diff)
Quote \jobname in lualatex formats if it contains spaces.
git-svn-id: svn://tug.org/texlive/trunk@18968 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/latexconfig')
-rw-r--r--Master/texmf-dist/tex/latex/latexconfig/dvilualatex.ini3
-rw-r--r--Master/texmf-dist/tex/latex/latexconfig/lualatex.ini4
-rw-r--r--Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.tex16
3 files changed, 22 insertions, 1 deletions
diff --git a/Master/texmf-dist/tex/latex/latexconfig/dvilualatex.ini b/Master/texmf-dist/tex/latex/latexconfig/dvilualatex.ini
index f0c47ffaeec..c213f6193b3 100644
--- a/Master/texmf-dist/tex/latex/latexconfig/dvilualatex.ini
+++ b/Master/texmf-dist/tex/latex/latexconfig/dvilualatex.ini
@@ -7,4 +7,7 @@
%
% the usual format initialization.
\scrollmode
+\let\dump\relax
\input latex.ltx
+\input lualatexquotejobname.tex
+\pdfprimitive\dump
diff --git a/Master/texmf-dist/tex/latex/latexconfig/lualatex.ini b/Master/texmf-dist/tex/latex/latexconfig/lualatex.ini
index 225bd4ced4f..ccab0f74f52 100644
--- a/Master/texmf-dist/tex/latex/latexconfig/lualatex.ini
+++ b/Master/texmf-dist/tex/latex/latexconfig/lualatex.ini
@@ -4,5 +4,7 @@
\input pdftexconfig.tex
% pdf output by default.
\scrollmode
+\let\dump\relax
\input latex.ltx
-
+\input lualatexquotejobname.tex
+\pdfprimitive\dump
diff --git a/Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.tex b/Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.tex
new file mode 100644
index 00000000000..19a1f8845e1
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.tex
@@ -0,0 +1,16 @@
+% $Id$
+% Manuel Pegourie-Gonnard, originally written 2010. WTFPL v2.
+%
+% Quote \jobname if it contains spaces, similarly to what pdfTeX does.
+%
+\everyjob\expandafter{\the\everyjob
+ \begingroup
+ \def\testsp#1 #2\relax{%
+ \ifx\relax#2\relax
+ \let\fixjobname\empty
+ \else
+ \edef\fixjobname{\def\noexpand\jobname{"\jobname"}}%
+ \fi}%
+ \edef\dotest{\noexpand\testsp\jobname\space\relax}\dotest
+ \expandafter\endgroup\fixjobname}
+\endinput