texlive[44698] Master/texmf-dist: l3build (25jun17)

commits+karl at tug.org commits+karl at tug.org
Sun Jun 25 23:51:47 CEST 2017


Revision: 44698
          http://tug.org/svn/texlive?view=revision&revision=44698
Author:   karl
Date:     2017-06-25 23:51:46 +0200 (Sun, 25 Jun 2017)
Log Message:
-----------
l3build (25jun17)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/l3build/README.md
    trunk/Master/texmf-dist/doc/latex/l3build/l3build.pdf
    trunk/Master/texmf-dist/source/latex/l3build/l3build.dtx
    trunk/Master/texmf-dist/tex/latex/l3build/l3build.lua
    trunk/Master/texmf-dist/tex/latex/l3build/regression-test.tex

Modified: trunk/Master/texmf-dist/doc/latex/l3build/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/l3build/README.md	2017-06-25 21:51:33 UTC (rev 44697)
+++ trunk/Master/texmf-dist/doc/latex/l3build/README.md	2017-06-25 21:51:46 UTC (rev 44698)
@@ -1,7 +1,7 @@
 l3build: a testing and building system for LaTeX3
 =================================================
 
-Release 2017/05/29
+Release 2017/06/25
 
 Overview
 --------
@@ -18,30 +18,12 @@
 are designed such that they can be readily used by others. Full
 documentation is provided.
 
-Discussion
-----------
-
-Discussion concerning the approach, suggestions for improvements,
-changes, additions, _etc._ should be addressed to the list
-[LaTeX-L](http://news.gmane.org/group/gmane.comp.tex.latex.latex3).
-
-You can subscribe to this list by sending mail to
-
-    listserv at urz.uni-heidelberg.de
-
-with the body containing
-
-    subscribe LATEX-L  <Your-First-Name> <Your-Second-Name>
-
 Issues
 ------
 
 The issue tracker for LaTeX3 is currently located
-[on GitHub](https://github.com/latex3/latex3/issues).
+[on GitHub](https://github.com/latex3/l3build/issues).
 
-Please report specific issues with LaTeX3 code there; more general
-discussion should be directed to the [LaTeX-L list](#Discussion).
-
 The LaTeX3 Project
 ------------------
 
@@ -69,8 +51,7 @@
 * Martin Schröder
 
 The development team can be contacted
-by e-mail: <latex-team at latex-project.org>; for general LaTeX3 discussion
-the [LaTeX-L list](#Discussion) should be used.
+by e-mail: <latex-team at latex-project.org>.
 
 -----
 

Modified: trunk/Master/texmf-dist/doc/latex/l3build/l3build.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/source/latex/l3build/l3build.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/l3build/l3build.dtx	2017-06-25 21:51:33 UTC (rev 44697)
+++ trunk/Master/texmf-dist/source/latex/l3build/l3build.dtx	2017-06-25 21:51:46 UTC (rev 44698)
@@ -71,27 +71,28 @@
 \luavarset{tdsdir}     {distribdir .. "/tds"}       {Generated folder where files are organised for a TDS.}
 \luavarset{tdsroot}    {"latex"}{Root directory of the TDS structure for the bundle/module to be installed into.}
 \luavarseparator
-\luavarset{bibfiles}        {\{"*.bib"\}}{\BibTeX{} database files.}
-\luavarset{binaryfiles}     {\{"*.pdf", "*.zip"\}}
-                            {Files to be added in binary mode to zip files.}
-\luavarset{bstfiles}        {\{"*.bst"\}}{\BibTeX{} style files.}
-\luavarset{checkfiles}      {\{~\}}{Extra files unpacked purely for tests}
-\luavarset{checksuppfiles}  { }{Files needed for performing regression tests.}
-\luavarset{cmdchkfiles}     {\{~\}}{Files need to perform command checking (\cls{l3doc}-based documentation only).}
-\luavarset{cleanfiles}      {\{"*.log", "*.pdf", "*.zip"\}}{Files to delete when cleaning.}
-\luavarset{demofiles}       {\{~\}}{Files which show how to use a module.}
-\luavarset{docfiles}        {\{~\}}{Files which are part of the documentation but should not be typeset.}
-\luavarset{excludefiles}    {\{"*\string~"\}}            {Files to ignore entirely (default for Emacs backup files).}
-\luavarset{installfiles}    {\{"*.sty"\}}         {Files to install to the \TeX{} tree and similar tasks.}
-\luavarset{makeindexfiles}  {\{"*.ist"\}}{MakeIndex files to be included in a TDS-style zip}
-\luavarset{sourcefiles}     {\{"*.dtx", "*.ins"\}}{Files to copy for unpacking.}
-\luavarset{textfiles}       {\{"*.md", "*.txt"\}}{Plain text files to send to CTAN as-is.}
-\luavarset{typesetdemofiles}{\{~\}}       {Files to typeset before the documentation (as demos), but where the PDF results are not included in the release.}
-\luavarset{typesetfiles}    {\{"*.dtx"\}} {Files to typeset for documentation.}
-\luavarset{typesetsuppfiles}{\{~\}}       {Files needed to support typesetting when \enquote{sandboxed}.}
-\luavarset{unpackfiles}     {\{"*.ins"\}} {Files to run to perform unpacking.}
-\luavarset{unpacksuppfiles} {\{~\}}       {Files needed to support unpacking when \enquote{sandboxed}.}
-\luavarset{versionfiles}    {\{"*.dtx"\}} {Files for automatic version editing.}
+\luavarset{bibfiles}          {\{"*.bib"\}}{\BibTeX{} database files.}
+\luavarset{binaryfiles}       {\{"*.pdf", "*.zip"\}}
+                              {Files to be added in binary mode to zip files.}
+\luavarset{bstfiles}          {\{"*.bst"\}}{\BibTeX{} style files.}
+\luavarset{checkfiles}        {\{~\}}{Extra files unpacked purely for tests}
+\luavarset{checksuppfiles}    { }{Files needed for performing regression tests.}
+\luavarset{cmdchkfiles}       {\{~\}}{Files need to perform command checking (\cls{l3doc}-based documentation only).}
+\luavarset{cleanfiles}        {\{"*.log", "*.pdf", "*.zip"\}}{Files to delete when cleaning.}
+\luavarset{demofiles}         {\{~\}}{Files which show how to use a module.}
+\luavarset{docfiles}          {\{~\}}{Files which are part of the documentation but should not be typeset.}
+\luavarset{excludefiles}      {\{"*\string~"\}}            {Files to ignore entirely (default for Emacs backup files).}
+\luavarset{installfiles}      {\{"*.sty"\}}         {Files to install to the \TeX{} tree and similar tasks.}
+\luavarset{makeindexfiles}    {\{"*.ist"\}}{MakeIndex files to be included in a TDS-style zip}
+\luavarset{sourcefiles}       {\{"*.dtx", "*.ins"\}}{Files to copy for unpacking.}
+\luavarset{textfiles}         {\{"*.md", "*.txt"\}}{Plain text files to send to CTAN as-is.}
+\luavarset{typesetdemofiles}  {\{~\}}       {Files to typeset before the documentation (as demos), but where the PDF results are not included in the release.}
+\luavarset{typesetfiles}      {\{"*.dtx"\}} {Files to typeset for documentation.}
+\luavarset{typesetsuppfiles}  {\{~\}}       {Files needed to support typesetting when \enquote{sandboxed}.}
+\luavarset{typesetsourcefiles}{\{~\}}       {Files to copy to unpacking when typesetting.}
+\luavarset{unpackfiles}       {\{"*.ins"\}} {Files to run to perform unpacking.}
+\luavarset{unpacksuppfiles}   {\{~\}}       {Files needed to support unpacking when \enquote{sandboxed}.}
+\luavarset{versionfiles}      {\{"*.dtx"\}} {Files for automatic version editing.}
 \luavarseparator
 \luavarset{bakext} {".bak"} {Extension of backup files.}
 \luavarset{dviext} {".dvi"} {Extension of DVI files.}
@@ -202,7 +203,7 @@
 %    }^^A
 % }
 %
-% \date{Released 2017/05/29}
+% \date{Released 2017/06/25}
 %
 % \maketitle
 % \tableofcontents
@@ -440,7 +441,13 @@
 % Files that match |typesetsuppfiles| in the |support| directory (|supportdir|) are copied into the |build/local| directory (|localdir|) for the typesetting compilation process.
 % Additional dependencies listed in the \var{typesetdeps} variable (empty by default) will also be installed.
 %
+% Source files specified in \var{sourcefiles} and \var{typesetsourcefiles}
+% are unpacked before the typesetting takes place. (In most cases
+% \var{typesetsourcefiles} will be mepty, but may be used where there are
+% files to unpack \emph{only} for typesetting.)
+%
 % If \var{typesetsearch} is \code{true} (default), standard \texttt{texmf} search trees are used in the typesetting compilation. If set to false, \emph{all} necessary files for compilation must be included in the |build/local| sandbox.
+%
 % \end{buildcmd}
 %
 % \begin{buildcmd}{doc \meta{name(s)}}
@@ -673,9 +680,6 @@
 % \end{itemize}
 % Modifications made in lines are:
 % \begin{itemize}
-%   \item Removal of the name of the test file itself.
-%   \item Removal of the |pdftex.map| load information given during
-%     first page shipout.
 %   \item Removal spaces at the start of lines.
 %   \item Removal of |./| at start of file names.
 %   \item Standardisation of the list of units known to \TeX{} (\pdfTeX{}
@@ -1157,11 +1161,20 @@
 %   \meta{target} directory.
 % \end{function}
 %
+% \begin{function}{dirname()}
+%   \begin{syntax}
+%     |dirname(|\meta{file}|)|
+%   \end{syntax}
+%   Returns a string comprising the path to a \meta{file} with the name removed
+%   (\emph{i.e.}~up to the last |/|). Where the \meta{file} has no path data,
+%   |"."| is returned.
+% \end{function}
+%
 % \begin{function}{basename()}
 %   \begin{syntax}
 %     |basename(|\meta{file}|)|
 %   \end{syntax}
-%   Returns a string comprising the full name of the file with the
+%   Returns a string comprising the full name of the \meta{file} with the
 %   path removed (\emph{i.e.}~from the last |/| onward).
 % \end{function}
 %
@@ -1243,6 +1256,14 @@
 %   error level.
 % \end{function}
 %
+% \begin{function}{spltpath()}
+%   \begin{syntax}
+%     |splitpath(|\meta{file}|)|
+%   \end{syntax}
+%   Returns two strings split at the last |/|: the \texttt{dirname()} and
+%   the |basename()|.
+% \end{function}
+%
 % \begin{function}{unix_to_win()}
 %   \begin{syntax}
 %     |unix_to_win(|\meta{path}|)|
@@ -1312,15 +1333,25 @@
 %
 % \subsection{Preliminaries}
 %
-% Unlike in the \LaTeXe{} regression test suite, reset catcodes: each test should set these
-% as appropriate. There's also a quick test for Con\TeX{}t: it defines |\unprotect|
-% which should be a reasonable marker (and is needed as some catcodes are otherwise
-% wrong).
+% We require \eTeX{}.
 %    \begin{macrocode}
+\begingroup\expandafter\expandafter\expandafter\endgroup
+\expandafter\ifx\csname eTeXversion\endcsname\relax
+  \errmessage{e-TeX is required to use regression-test.tex}%
+  \expandafter\endinput
+\fi
+%    \end{macrocode}
+%
+% \begin{macro}{\reset at catcodes}
+%   Unlike in the \LaTeXe{} regression test suite, reset catcodes: each test
+%   should set these as appropriate. There's also a quick test for Con\TeX{}t:
+%   it defines |\unprotect| which should be a reasonable marker (and is
+%   needed as some catcodes are otherwise wrong).
+%    \begin{macrocode}
 \ifx\unprotect\undefined
   \expandafter\edef\csname reset\string @catcodes\endcsname{%
     \catcode`\noexpand\@=\the\catcode`\@\relax
-  }
+  }%
   \catcode`\@=11 %
 \else
   \unprotect
@@ -1327,6 +1358,8 @@
   \def\reset at catcodes{\protect}%
 \fi
 %    \end{macrocode}
+% \end{macro}
+%
 % Put \TeX{} into scroll mode, and stop it showing the
 % implementation details of macros in error messages.
 %    \begin{macrocode}
@@ -1341,16 +1374,20 @@
 \showboxdepth=\maxdimen
 %    \end{macrocode}
 %
-% The |\showoutput| command of \LaTeX{} calls |\loggingoutput| which in
-% turn calls |\errorstopmode| but we want to continue running without
-% any stops.
+% \begin{macro}{\logginoutput}
+%   The |\showoutput| command of \LaTeX{} calls |\loggingoutput| which in turn
+%   calls |\errorstopmode| but we want to continue running without any stops.
 %    \begin{macrocode}
-\def\loggingoutput{\tracingoutput1
-    \showboxbreadth\maxdimen\showboxdepth\maxdimen}
+\def\loggingoutput{%
+  \tracingoutput=1 %
+  \showboxbreadth=\maxdimen
+  \showboxdepth=\maxdimen
+}
 %    \end{macrocode}
+% \end{macro}
 %
-% Set the newline character: \LaTeXe{} does this but plain-based formats
-% do not.
+% Set the newline character: \LaTeXe{} does this but plain-based formats do
+% not.
 %    \begin{macrocode}
 \newlinechar=`\^^J
 %    \end{macrocode}
@@ -1357,8 +1394,10 @@
 %
 % \subsection{Commands in test files}
 %
-% A long version of |\typeout|, because tests may contain |\par| tokens.
-% Besides, with that |\TYPE|, we can do |\TYPE { ... \TRUE ... \NEWLINE ... }|.
+% \begin{macro}{\LONGTYPEOUT, \TYPE}
+%   A long version of |\typeout|, because tests may contain |\par| tokens.
+%   Besides, with that |\TYPE|, we can do
+%   |\TYPE { ... \TRUE ... \NEWLINE ... }|.
 %    \begin{macrocode}
 \long\def\LONGTYPEOUT#1{%
   \begingroup
@@ -1369,48 +1408,24 @@
 \let\TYPE\LONGTYPEOUT
 %    \end{macrocode}
 %
-% Start the test, after the optional |\documentclass|
-% |\begin{document}| commands with |\START|.  All lines in the |.log| file
-% before this will be ignored.
-%
-% It also prints a DocStrip-style
-% character table in the |.tlg| file.
-% Is this necessary any more? Probably too late to remove it.
+% \begin{macro}{\STARTMESSAGE, \START}
+%   Start the test, after the optional |\documentclass|
+%   |\begin{document}| commands with |\START|.  All lines in the |.log| file
+%   before this will be ignored.
 %    \begin{macrocode}
 \def\STARTMESSAGE{This is a generated file for the l3build validation system.}
-\def\START{\LONGTYPEOUT{^^JSTART-TEST-LOG^^J^^J%
-   \STARTMESSAGE%
-^^J^^JDon't change this file in any respect.%
-^^J^^J}}
-\begingroup
-\catcode`\^^\=0
-\catcode`\^^A=\catcode`\%
-^^\catcode`^^\ =11
-^^\catcode`^^\%=11
-^^\catcode`^^\#=11
-^^\catcode`^^\~=11
-^^\endlinechar=`^^\^^J
-^^\catcode`^^\\=11^^A
-^^\gdef^^\CTable{
-%% \CharacterTable
-%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
-%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
-%%   Digits        \0\1\2\3\4\5\6\7\8\9
-%%   Exclamation   \!     Double quote  \"     Hash (number) \#
-%%   Dollar        \$     Percent       \%     Ampersand     \&
-%%   Acute accent  \'     Left paren    \(     Right paren   \)
-%%   Asterisk      \*     Plus          \+     Comma         \,
-%%   Minus         \-     Point         \.     Solidus       \/
-%%   Colon         \:     Semicolon     \;     Less than     \<
-%%   Equals        \=     Greater than  \>     Question mark \?
-%%   Commercial at \@     Left bracket  \[     Backslash     \\
-%%   Right bracket \]     Circumflex    \^     Underscore    \_
-%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
-%%   Right brace   \}     Tilde         \~}
-%%
-}^^A
-^^\endgroup{}%
+\def\START{%
+  \LONGTYPEOUT{^^JSTART-TEST-LOG^^J}%
+  \LONGTYPEOUT{^^J%
+     \STARTMESSAGE%
+     ^^J^^JDon't change this file in any respect.%
+     ^^J^^J%
+  }%
+}
 %    \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\@@@end, \END}
 % The test should end with |\END| or |\end{document}|
 % or |\bye| in plain \TeX{}.
 %    \begin{macrocode}
@@ -1419,18 +1434,16 @@
 \else
   \let\@@@end\@@end
 \fi
-\def\END
-  {%
-    \ifx\currentiflevel\@undefined\else
-      \ifnum\currentgrouplevel>0 %
-        \LONGTYPEOUT{Bad grouping: \the\currentgrouplevel!}%
-      \fi
-      \ifnum\currentiflevel>2 %
-        \LONGTYPEOUT{Bad conditionals: \the\numexpr\currentiflevel-2!}%
-      \fi
-    \fi
-    \LONGTYPEOUT{^^JEND-TEST-LOG^^J}\@@@end
-  }
+\def\END{%
+  \ifnum\currentgrouplevel>0 %
+    \LONGTYPEOUT{Bad grouping: \the\currentgrouplevel!}%
+  \fi
+  \ifnum\currentiflevel>2 %
+    \LONGTYPEOUT{Bad conditionals: \the\numexpr\currentiflevel-2!}%
+  \fi
+  \LONGTYPEOUT{^^JEND-TEST-LOG^^J}%
+  \@@@end
+}
 \ifx\@@end\@undefined
   \let\end\END
 \else
@@ -1437,150 +1450,71 @@
   \let\@@end\END
 \fi
 %    \end{macrocode}
-% After the |\START| should come declarations of the format and style
-% options being used.
+% \end{macro}
+%
+% \begin{macro}{\OMIT, \TIMO}
+%   Surround commands which produce irrelevant lines in the |.log| file by
+%   |\OMIT|\dots|\TIMO|
 %    \begin{macrocode}
-\def\FORMAT#1{\LONGTYPEOUT{Format: #1}%
-  \def\@tempa{#1}\ifx\@tempa\@EJ\else
-   \OMIT\TYPE{WARNING: Declared format #1,^^JActual format \@EJ}\TIMO\fi}
-%    \end{macrocode}
-% The old version got this information from everyjob,
-% but that does not work with \LaTeXe\ as |\everyjob| is cleared.
-%    \begin{macrocode}
-\edef\@EJ{\fmtname <\fmtversion>}
-%    \end{macrocode}
-% Some author info:
-%    \begin{macrocode}
-\def\AUTHOR#1{\LONGTYPEOUT{Author: #1}}
-%    \end{macrocode}
-% Surround commands which produce irrelevant lines in the .log file by
-% |\OMIT|\dots|\TIMO|
-%    \begin{macrocode}
 \def\OMIT{\LONGTYPEOUT{OMIT}}
 \def\TIMO{\LONGTYPEOUT{TIMO}}
 %    \end{macrocode}
-% Not all packages declare themselves to the log file, and we can not
-% rely on TeX`s output as it includes full path names, and does not
-% include version numbers etc.
+% \end{macro}
 %
-% If the class or package is loaded with options, you may
-% specify the options in the |\CLASS| (|\PACKAGE|) declaration. eg:
-% \begin{verbatim}
-% \CLASS[german,a4page]{article v2.0 1994/01/02}
-% \PACKAGE{ifthen v2.2 1993/11/12}
-% \PACKAGE[dvips]{graphics v 3.8 1994/02/02}
-% \end{verbatim}
-%    \begin{macrocode}
-\def\CLASS{\@ifnextchar[\OPTCLASS\XCLASS}
-\def\OPTCLASS[#1]#2{%
-  \TYPE{Main Class: #2^^J\space\space\space\space Options: #1}}
-\def\XCLASS#1{%
-  \TYPE{Main Class: #1}}
-\def\PACKAGE{\@ifnextchar[\OPTPACKAGE\XPACKAGE}
-\def\OPTPACKAGE[#1]#2{%
-  \TYPE{Package: #2^^J\space\space\space\space Options: #1}}
-\def\XPACKAGE#1{%
-  \TYPE{Package: #1}}
-%    \end{macrocode}
-%
-% The commands above require 2e's \verb|\@ifnextchar|, so copy that definition verbatim if necessary:
-%    \begin{macrocode}
-\ifx\@ifnextchar\@undefined
-\long\def\@ifnextchar#1#2#3{%
-  \let\reserved at d=#1%
-  \def\reserved at a{#2}%
-  \def\reserved at b{#3}%
-  \futurelet\@let at token\@ifnch}
-\def\@ifnch{%
-  \ifx\@let at token\@sptoken
-    \let\reserved at c\@xifnch
-  \else
-    \ifx\@let at token\reserved at d
-      \let\reserved at c\reserved at a
-    \else
-      \let\reserved at c\reserved at b
-    \fi
-  \fi
-  \reserved at c}
-\def\:{\let\@sptoken= } \: % this makes \@sptoken a space token
-\def\:{\@xifnch} \expandafter\def\: {\futurelet\@let at token\@ifnch}
-\fi
-%    \end{macrocode}
-% After the above declarations, and before the main tests, you may
-% optionally declare' all the commands in the `module' that you are
-% about to test. These commands will be registered as defined,
-% undefined or relaxed (i.e.~|\let| to |\relax|). You may wish to declare
-% commands not currently implemented, so that if they are added at a
-% later stage, the test will fail, reminding someone to document the
-% fact that the user interface has changed.
-%    \begin{macrocode}
-\def\CHECKCOMMAND#1{%
-  \ifx#1\@undefined\LONGTYPEOUT{Undefined \string#1}\else
-  \ifx#1\relax\LONGTYPEOUT{Relaxed \space\space\string#1}\else
-         \LONGTYPEOUT{Defined \space\space\string#1}\fi\fi}
-%    \end{macrocode}
 % To allow testing of possible changes, we allow extra code to be read
 % in before the test starts. The necessary code should be placed in a
 % file |regression-test.cfg|.
 %    \begin{macrocode}
 \ifx\InputIfFileExists\@undefined
-\newread\@inputcheck
-\long\def\InputIfFileExists#1#2#3{%
-  \openin\@inputcheck#1\relax
-  \ifeof\@inputcheck
-    \def\reserved at a{#3}%
-  \else
-    \def\reserved at a{#2\input #1\relax}%
-  \fi
-  \closein\@inputcheck
-  \reserved at a}
+  \newread\@inputcheck
+  \long\def\InputIfFileExists#1#2#3{%
+    \openin\@inputcheck#1\relax
+    \ifeof\@inputcheck
+      \def\reserved at a{#3}%
+    \else
+      \def\reserved at a{#2\input #1\relax}%
+    \fi
+    \closein\@inputcheck
+    \reserved at a
+  }%
 \fi
 \InputIfFileExists{regression-test.cfg}
-      {\LONGTYPEOUT{^^J***^^Jregression-test.cfg in operation^^J***^^J}}{}
+  {\LONGTYPEOUT{^^J***^^Jregression-test.cfg in operation^^J***^^J}}{}
 %    \end{macrocode}
 %
-% Load the map file early so it does not appear in the log.
-%    \begin{macrocode}
-\ifdefined\pdfoutput
-  \ifnum\pdfoutput>0 %
-    \pdfmapfile{pdftex.map}%
-  \fi
-\else
-  \ifdefined\outputmode
-  \ifnum\outputmode>0 %
-    \pdfextension mapfile{pdftex.map}%
-  \fi
-  \fi
-\fi
-%    \end{macrocode}
-%
 % \subsection{Formatting the \texttt{.log} file}
 %
-% We are not starved for space in the log file output, so let's make it as
-% verbose as is useful when reading the |.diff|'s.
+% \begin{macro}{\gTESTint}
+%   For tracking the total number of tests.
 %    \begin{macrocode}
-\newcount \gTESTint
+\newcount\gTESTint
+%     \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}
+%   {\SEPARATOR, \TEST, \TESTEXP, \TRUE, \FALSE, \YES, \NO, \NEWLINE}
+%   We are not starved for space in the log file output, so let's make it as
+%   verbose as is useful when reading the |.diff|'s.
+%    \begin{macrocode}
 \def\SEPARATOR{%
   \TYPE{%
     ============================================================%
   }%
 }
-%    \end{macrocode}
-%    \begin{macrocode}
 \long\def\TEST#1#2{%
-  \advance \gTESTint 1 %
+  \global\advance\gTESTint by 1 %
   \SEPARATOR
-  \LONGTYPEOUT{%
-    TEST \the\gTESTint: \detokenize{#1}}%
+  \LONGTYPEOUT{TEST \the\gTESTint: \detokenize{#1}}%
   \SEPARATOR
   \begingroup
     \let\TYPE\LONGTYPEOUT
     #2%
   \endgroup
-  \SEPARATOR \LONGTYPEOUT{}%
+  \SEPARATOR
+  \LONGTYPEOUT{}%
 }
 \long\def\TESTEXP#1#2{%
-  \advance \gTESTint 1 %
+  \global\advance\gTESTint by 1 %
   \SEPARATOR
   \LONGTYPEOUT{%
     TEST \the\gTESTint: \detokenize{#1}}%
@@ -1598,9 +1532,26 @@
 \def \NO    {\TYPE{NO}}
 \def \NEWLINE {\TYPE{^^J}}
 %    \end{macrocode}
+% \end{macro}
 %
 % \subsection{Suppressing variable data in output}
 %
+% Load the map file early so it does not appear in the log.
+%    \begin{macrocode}
+\ifx\pdfoutput\@undefined
+  \ifx\outputmode\@undefined
+  \else
+    \ifnum\outputmode>0 %
+      \pdfextension mapfile{pdftex.map}%
+    \fi
+  \fi
+\else
+  \ifnum\pdfoutput>0 %
+    \pdfmapfile{pdftex.map}%
+  \fi
+\fi
+%    \end{macrocode}
+%
 % To make any PDF file produced comparable we need to suppress various
 % pieces of data. This works in concert with setting the epoch from the
 % environment side (as not all output can be controlled here). We are

Modified: trunk/Master/texmf-dist/tex/latex/l3build/l3build.lua
===================================================================
--- trunk/Master/texmf-dist/tex/latex/l3build/l3build.lua	2017-06-25 21:51:33 UTC (rev 44697)
+++ trunk/Master/texmf-dist/tex/latex/l3build/l3build.lua	2017-06-25 21:51:46 UTC (rev 44698)
@@ -23,7 +23,7 @@
 --]]
 
 -- Version information
-release_date = "2017/05/29"
+release_date = "2017/06/25"
 
 -- "module" is a deprecated function in Lua 5.2: as we want the name
 -- for other purposes, and it should eventually be 'free', simply
@@ -85,26 +85,27 @@
 -- File types for various operations
 -- Use Unix-style globs
 -- All of these may be set earlier, so a initialised conditionally
-bibfiles         = bibfiles         or {"*.bib"}
-binaryfiles      = binaryfiles      or {"*.pdf", "*.zip"}
-bstfiles         = bstfiles         or {"*.bst"}
-checkfiles       = checkfiles       or { }
-checksuppfiles   = checksuppfiles   or { }
-cmdchkfiles      = cmdchkfiles      or { }
-cleanfiles       = cleanfiles       or {"*.log", "*.pdf", "*.zip"}
-demofiles        = demofiles        or { }
-docfiles         = docfiles         or { }
-excludefiles     = excludefiles     or {"*~"}
-installfiles     = installfiles     or {"*.sty"}
-makeindexfiles   = makeindexfiles   or {"*.ist"}
-sourcefiles      = sourcefiles      or {"*.dtx", "*.ins"}
-textfiles        = textfiles        or {"*.md", "*.txt"}
-typesetdemofiles = typesetdemofiles or { }
-typesetfiles     = typesetfiles     or {"*.dtx"}
-typesetsuppfiles = typesetsuppfiles or { }
-unpackfiles      = unpackfiles      or {"*.ins"}
-unpacksuppfiles  = unpacksuppfiles  or { }
-versionfiles     = versionfiles     or {"*.dtx"}
+bibfiles           = bibfiles           or {"*.bib"}
+binaryfiles        = binaryfiles        or {"*.pdf", "*.zip"}
+bstfiles           = bstfiles           or {"*.bst"}
+checkfiles         = checkfiles         or { }
+checksuppfiles     = checksuppfiles     or { }
+cmdchkfiles        = cmdchkfiles        or { }
+cleanfiles         = cleanfiles         or {"*.log", "*.pdf", "*.zip"}
+demofiles          = demofiles          or { }
+docfiles           = docfiles           or { }
+excludefiles       = excludefiles       or {"*~"}
+installfiles       = installfiles       or {"*.sty"}
+makeindexfiles     = makeindexfiles     or {"*.ist"}
+sourcefiles        = sourcefiles        or {"*.dtx", "*.ins"}
+textfiles          = textfiles          or {"*.md", "*.txt"}
+typesetdemofiles   = typesetdemofiles   or { }
+typesetfiles       = typesetfiles       or {"*.dtx"}
+typesetsuppfiles   = typesetsuppfiles   or { }
+typesetsourcefiles = typesetsourcefiles or { }
+unpackfiles        = unpackfiles        or {"*.ins"}
+unpacksuppfiles    = unpacksuppfiles    or { }
+versionfiles       = versionfiles       or {"*.dtx"}
 
 -- Roots which should be unpacked to support unpacking/testing/typesetting
 checkdeps   = checkdeps   or { }
@@ -489,7 +490,7 @@
 -- Copy files 'quietly'
 function cp(glob, source, dest)
   local errorlevel
-  for _,i in ipairs(filelist(source, glob)) do
+  for i,_ in pairs(tree(source, glob)) do
     local source = source .. "/" .. i
     if os_type == "windows" then
       if lfs_attributes(source)["mode"] == "directory" then
@@ -562,6 +563,58 @@
   return files
 end
 
+-- Does what filelist does, but can also glob subdirectories. In the returned
+-- table, the keys are paths relative to the given starting path, the values
+-- are their counterparts relative to the current working directory.
+function tree(path, glob)
+  function cropdots(path)
+    return gsub(gsub(path, "^%./", ""), "/%./", "/")
+  end
+  function always_true()
+    return true
+  end
+  function is_dir(file)
+    return lfs.attributes(file)["mode"] == "directory"
+  end
+  local dirs = {["."]=cropdots(path)}
+  for pattern, critereon in gmatch(cropdots(glob), "([^/]+)(/?)") do
+    local critereon = critereon == "/" and is_dir or always_true
+    function fill(path, dir, table)
+      for _, file in ipairs(filelist(dir, pattern)) do
+        local fullpath = path .. "/" .. file
+        if file ~= "." and file ~= ".." and
+          fullpath ~= maindir .. "/build" and
+          (string.sub(pattern, 1, 1) == "."
+            or string.sub(file, 1, 1) ~= ".")
+        then
+          local fulldir = dir .. "/" .. file
+          if critereon(fulldir) then
+            table[fullpath] = fulldir
+          end
+        end
+      end
+    end
+    local newdirs = {}
+    if pattern == "**" then
+      while true do
+        path, dir = next(dirs)
+        if not path then
+          break
+        end
+        dirs[path] = nil
+        newdirs[path] = dir
+        fill(path, dir, dirs)
+      end
+    else
+      for path, dir in pairs(dirs) do
+        fill(path, dir, newdirs)
+      end
+    end
+    dirs = newdirs
+  end
+  return dirs
+end
+
 function mkdir(dir)
   if os_type == "windows" then
     -- Windows (with the extensions) will automatically make directory trees
@@ -658,7 +711,7 @@
 
 -- Set up the check system files: needed for checking one or more tests and
 -- for saving the test files
-local function checkinit()
+function checkinit()
   cleandir(testdir)
   depinstall(checkdeps)
   -- Copy dependencies to the test directory itself: this makes the paths
@@ -801,26 +854,17 @@
     end
     local line = (lastline or "") .. line
     lastline = ""
-    -- Remove test file name from lines
-    -- This needs to extract the base name from the log name,
-    -- and one to allow for the case that there might be "-" chars
-    -- in the name (other cases are ignored)
-    line = gsub(
-      line,
-      gsub(
-        match("/" .. logfile, ".*/(.*)%" .. logext .. "$"),
-        "-",
-        "%%-"
-      ),
-      ""
-    )
     -- Zap ./ at begin of filename
     line = gsub(line, "%(%.%/", "(")
     -- Zap paths if places other than 'here' are accessible
     if checksearch then
-      local pattern = "%w?:?/[^ ]*/([^/%(%)]*%.%w*)"
+      -- The pattern excludes < and > as the image part can have
+      -- several entries on one line
+      local pattern = "%w?:?/[^ %<%>]*/([^/%(%)]*%.%w*)"
       -- Files loaded from TeX: all start ( -- )
       line = gsub(line, "%(" .. pattern, "(../%1")
+      -- Images
+      line = gsub(line, "<" .. pattern .. ">", "<../%1>")
       -- luaotfload files start with keywords
       line = gsub(line, "from " .. pattern .. "%(", "from. ./%1(")
       line = gsub(line, ": " .. pattern .. "%)", ": ../%1)")
@@ -849,6 +893,7 @@
     end
     -- Remove 'normal' direction information on boxes with (u)pTeX
     line = gsub(line, ",? yoko direction,?", "")
+    line = gsub(line, ",? yoko%(math%) direction,?", "")
     -- Remove the \special line that in DVI mode keeps PDFs comparable
     if match(line, "^%.*\\special%{pdf: docinfo << /Creator") then
       return ""
@@ -1402,15 +1447,28 @@
   end
 end
 
--- Strip the path from a file name (if present)
+-- Split a path into file and directory component
+function splitpath(file)
+  local path, name = match(file, "^(.*)/([^/]*)$")
+  if path then
+    return path, name
+  else
+    return ".", file
+  end
+end
+
+-- Arguably clearer names
 function basename(file)
-  local name = match(file, "^.*/([^/]*)$")
-  return name or file
+  return(select(2, splitpath(file)))
 end
 
+function dirname(file)
+  return(select(1, splitpath(file)))
+end
+
 -- Strip the extension from a file name (if present)
 function jobname(file)
-  local name = match(basename(file), "^(.*)%.")
+  local name = match(select(2, splitpath(file)), "^(.*)%.")
   return name or file
 end
 
@@ -1424,12 +1482,14 @@
 --
 
 -- An auxiliary used to set up the environmental variables
-function runtool(envvar, command)
+function runtool(subdir, dir, envvar, command)
+  dir = dir or "."
   return(
     run(
-      typesetdir,
+      typesetdir .. "/" .. subdir,
       os_setenv .. " " .. envvar .. "=." .. os_pathsep
-        .. abspath(localdir)
+        .. abspath(localdir) .. os_pathsep
+        .. abspath(dir .. "/" .. subdir)
         .. (typesetsearch and os_pathsep or "") ..
       os_concat ..
       command
@@ -1437,16 +1497,17 @@
   )
 end
 
-function biber(name)
+function biber(name, dir)
   if fileexists(typesetdir .. "/" .. name .. ".bcf") then
+    local path, name = splitpath(name)
     return(
-      runtool("BIBINPUTS",  biberexe .. " " .. biberopts .. " " .. name)
+      runtool(path, dir, "BIBINPUTS",  biberexe .. " " .. biberopts .. " " .. name)
     )
   end
   return 0
 end
 
-function bibtex(name)
+function bibtex(name, dir)
   if fileexists(typesetdir .. "/" .. name .. ".aux") then
     -- LaTeX always generates an .aux file, so there is a need to
     -- look inside it for a \citation line
@@ -1456,6 +1517,7 @@
     else
      grep = "\\\\\\\\"
     end
+    local path, name = splitpath(name)
     if run(
         typesetdir,
         os_grepexe .. " \"^" .. grep .. "citation{\" " .. name .. ".aux > "
@@ -1468,6 +1530,7 @@
       return(
         -- Cheat slightly as we need to set two variables
         runtool(
+          path, dir,
           "BIBINPUTS",
           os_setenv .. " BSTINPUTS=." .. os_pathsep
             .. abspath(localdir)
@@ -1481,14 +1544,16 @@
   return 0
 end
 
-function makeindex(name, inext, outext, logext, style)
+function makeindex(name, dir, inext, outext, logext, style)
   if fileexists(typesetdir .. "/" .. name .. inext) then
+    local path, name = splitpath(name)
     return(
       runtool(
+        path, dir,
         "INDEXSTYLE",
         makeindexexe .. " " .. makeindexopts .. " "
           .. " -s " .. style .. " -o " .. name .. outext
-          .. " -t " .. name .. logext .. " "  .. name .. inext
+          .. " -t " .. name .. " "  .. name .. inext
       )
     )
   end
@@ -1495,20 +1560,22 @@
   return 0
 end
 
-function tex(file)
+function tex(file, dir)
+  local path, name = splitpath(file)
   return(
     runtool(
+      path, dir,
       "TEXINPUTS",
       typesetexe .. " " .. typesetopts .. " \"" .. typesetcmds
-        .. "\\input " .. file .. "\""
+        .. "\\input " .. name .. "\""
     )
   )
 end
 
-function typesetpdf(file)
+function typesetpdf(file, dir)
   local name = jobname(file)
   print("Typesetting " .. name)
-  local errorlevel = typeset(file)
+  local errorlevel = typeset(file, dir)
   if errorlevel == 0 then
     os_remove(name .. ".pdf")
     cp(name .. ".pdf", typesetdir, ".")
@@ -1518,24 +1585,25 @@
   return errorlevel
 end
 
-typeset = typeset or function(file)
-  local errorlevel = tex(file)
+typeset = typeset or function(file, dir)
+  dir = dir or "."
+  local errorlevel = tex(file, dir)
   if errorlevel ~= 0 then
     return errorlevel
   else
     local name = jobname(file)
-    errorlevel = biber(name) + bibtex(name)
+    errorlevel = biber(name, dir) + bibtex(name, dir)
     if errorlevel == 0 then
-      local function cycle(name)
+      local function cycle(name, dir)
         return(
-          makeindex(name, ".glo", ".gls", ".glg", glossarystyle) +
-          makeindex(name, ".idx", ".ind", ".ilg", indexstyle)    +
-          tex(file)
+          makeindex(name, dir, ".glo", ".gls", ".glg", glossarystyle) +
+          makeindex(name, dir, ".idx", ".ind", ".ilg", indexstyle)    +
+          tex(file, dir)
         )
       end
-      errorlevel = cycle(name)
+      errorlevel = cycle(name, dir)
       if errorlevel == 0 then
-        errorlevel = cycle(name)
+        errorlevel = cycle(name, dir)
       end
     end
     return errorlevel
@@ -1859,12 +1927,12 @@
     cp(i, supportdir, typesetdir)
   end
   depinstall(typesetdeps)
-  unpack()
+  unpack({sourcefiles, typesetsourcefiles})
   -- Main loop for doc creation
   for _, typesetfiles in ipairs({typesetdemofiles, typesetfiles}) do
     for _,i in ipairs(typesetfiles) do
       for _, dir in ipairs({unpackdir, typesetdir}) do
-        for _,j in ipairs(filelist(dir, i)) do
+        for j,_ in pairs(tree(dir, i)) do
           -- Allow for command line selection of files
           local typeset = true
           if files and next(files) then
@@ -1877,7 +1945,7 @@
             end
           end
           if typeset then
-            local errorlevel = typesetpdf(abspath(dir) .. "/" .. j)
+            local errorlevel = typesetpdf(j, dir)
             if errorlevel ~= 0 then
               return errorlevel
             end
@@ -2068,12 +2136,12 @@
 
 -- Unpack the package files using an 'isolated' system: this requires
 -- a copy of the 'basic' DocStrip program, which is used then removed
-function unpack()
+function unpack(sources)
   local errorlevel = depinstall(unpackdeps)
   if errorlevel ~= 0 then
     return errorlevel
   end
-  errorlevel = bundleunpack()
+  errorlevel = bundleunpack({"."}, sources)
   if errorlevel ~= 0 then
     return errorlevel
   end
@@ -2088,7 +2156,7 @@
 
 -- Split off from the main unpack so it can be used on a bundle and not
 -- leave only one modules files
-bundleunpack = bundleunpack or function(sourcedir)
+bundleunpack = bundleunpack or function(sourcedir, sources)
   local errorlevel = mkdir(localdir)
   if errorlevel ~=0 then
     return errorlevel
@@ -2098,10 +2166,12 @@
     return errorlevel
   end
   for _,i in ipairs(sourcedir or {"."}) do
-    for _,j in ipairs(sourcefiles) do
-      errorlevel = cp(j, i, unpackdir)
-      if errorlevel ~=0 then
-        return errorlevel
+    for _,j in ipairs(sources or {sourcefiles}) do
+      for _,k in ipairs(j) do
+        errorlevel = cp(k, i, unpackdir)
+        if errorlevel ~=0 then
+          return errorlevel
+        end
       end
     end
   end
@@ -2112,7 +2182,7 @@
     end
   end
   for _,i in ipairs(unpackfiles) do
-    for _,j in ipairs(filelist(unpackdir, i)) do
+    for j,_ in pairs(tree(unpackdir, i)) do
       -- This 'yes' business is needed to pass a series of "y\n" to
       -- TeX if \askforoverwrite is true
       -- That is all done using a file as it's the only way on Windows and
@@ -2119,13 +2189,14 @@
       -- on Unix the "yes" command can't be used inside execute (it never
       -- stops, which confuses Lua)
       execute(os_yes .. ">>" .. localdir .. "/yes")
+      local path, name = splitpath(j)
       local localdir = abspath(localdir)
       errorlevel = run(
-        unpackdir,
+        unpackdir .. "/" .. path,
         os_setenv .. " TEXINPUTS=." .. os_pathsep
           .. localdir .. (unpacksearch and os_pathsep or "") ..
         os_concat ..
-        unpackexe .. " " .. unpackopts .. " " .. j .. " < "
+        unpackexe .. " " .. unpackopts .. " " .. name .. " < "
           .. localdir .. "/yes"
           .. (optquiet and (" > " .. os_null) or "")
       )

Modified: trunk/Master/texmf-dist/tex/latex/l3build/regression-test.tex
===================================================================
--- trunk/Master/texmf-dist/tex/latex/l3build/regression-test.tex	2017-06-25 21:51:33 UTC (rev 44697)
+++ trunk/Master/texmf-dist/tex/latex/l3build/regression-test.tex	2017-06-25 21:51:46 UTC (rev 44698)
@@ -18,10 +18,15 @@
 %% This file is part of the "l3build bundle" (The Work in LPPL)
 %% and all files in that bundle must be distributed together.
 %% 
+\begingroup\expandafter\expandafter\expandafter\endgroup
+\expandafter\ifx\csname eTeXversion\endcsname\relax
+  \errmessage{e-TeX is required to use regression-test.tex}%
+  \expandafter\endinput
+\fi
 \ifx\unprotect\undefined
   \expandafter\edef\csname reset\string @catcodes\endcsname{%
     \catcode`\noexpand\@=\the\catcode`\@\relax
-  }
+  }%
   \catcode`\@=11 %
 \else
   \unprotect
@@ -31,8 +36,11 @@
 \errorcontextlines=-1 %
 \showboxbreadth=\maxdimen
 \showboxdepth=\maxdimen
-\def\loggingoutput{\tracingoutput1
-    \showboxbreadth\maxdimen\showboxdepth\maxdimen}
+\def\loggingoutput{%
+  \tracingoutput=1 %
+  \showboxbreadth=\maxdimen
+  \showboxdepth=\maxdimen
+}
 \newlinechar=`\^^J
 \long\def\LONGTYPEOUT#1{%
   \begingroup
@@ -42,127 +50,52 @@
 }
 \let\TYPE\LONGTYPEOUT
 \def\STARTMESSAGE{This is a generated file for the l3build validation system.}
-\def\START{\LONGTYPEOUT{^^JSTART-TEST-LOG^^J^^J%
-   \STARTMESSAGE%
-^^J^^JDon't change this file in any respect.%
-^^J^^J}}
-\begingroup
-\catcode`\^^\=0
-\catcode`\^^A=\catcode`\%
-^^\catcode`^^\ =11
-^^\catcode`^^\%=11
-^^\catcode`^^\#=11
-^^\catcode`^^\~=11
-^^\endlinechar=`^^\^^J
-^^\catcode`^^\\=11^^A
-^^\gdef^^\CTable{
-%% \CharacterTable
-%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
-%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
-%%   Digits        \0\1\2\3\4\5\6\7\8\9
-%%   Exclamation   \!     Double quote  \"     Hash (number) \#
-%%   Dollar        \$     Percent       \%     Ampersand     \&
-%%   Acute accent  \'     Left paren    \(     Right paren   \)
-%%   Asterisk      \*     Plus          \+     Comma         \,
-%%   Minus         \-     Point         \.     Solidus       \/
-%%   Colon         \:     Semicolon     \;     Less than     \<
-%%   Equals        \=     Greater than  \>     Question mark \?
-%%   Commercial at \@     Left bracket  \[     Backslash     \\
-%%   Right bracket \]     Circumflex    \^     Underscore    \_
-%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
-%%   Right brace   \}     Tilde         \~}
-%%
-}^^A
-^^\endgroup{}%
+\def\START{%
+  \LONGTYPEOUT{^^JSTART-TEST-LOG^^J}%
+  \LONGTYPEOUT{^^J%
+     \STARTMESSAGE%
+     ^^J^^JDon't change this file in any respect.%
+     ^^J^^J%
+  }%
+}
 \ifx\@@end\@undefined
   \let\@@@end\end
 \else
   \let\@@@end\@@end
 \fi
-\def\END
-  {%
-    \ifx\currentiflevel\@undefined\else
-      \ifnum\currentgrouplevel>0 %
-        \LONGTYPEOUT{Bad grouping: \the\currentgrouplevel!}%
-      \fi
-      \ifnum\currentiflevel>2 %
-        \LONGTYPEOUT{Bad conditionals: \the\numexpr\currentiflevel-2!}%
-      \fi
-    \fi
-    \LONGTYPEOUT{^^JEND-TEST-LOG^^J}\@@@end
-  }
+\def\END{%
+  \ifnum\currentgrouplevel>0 %
+    \LONGTYPEOUT{Bad grouping: \the\currentgrouplevel!}%
+  \fi
+  \ifnum\currentiflevel>2 %
+    \LONGTYPEOUT{Bad conditionals: \the\numexpr\currentiflevel-2!}%
+  \fi
+  \LONGTYPEOUT{^^JEND-TEST-LOG^^J}%
+  \@@@end
+}
 \ifx\@@end\@undefined
   \let\end\END
 \else
   \let\@@end\END
 \fi
-\def\FORMAT#1{\LONGTYPEOUT{Format: #1}%
-  \def\@tempa{#1}\ifx\@tempa\@EJ\else
-   \OMIT\TYPE{WARNING: Declared format #1,^^JActual format \@EJ}\TIMO\fi}
-\edef\@EJ{\fmtname <\fmtversion>}
-\def\AUTHOR#1{\LONGTYPEOUT{Author: #1}}
 \def\OMIT{\LONGTYPEOUT{OMIT}}
 \def\TIMO{\LONGTYPEOUT{TIMO}}
-\def\CLASS{\@ifnextchar[\OPTCLASS\XCLASS}
-\def\OPTCLASS[#1]#2{%
-  \TYPE{Main Class: #2^^J\space\space\space\space Options: #1}}
-\def\XCLASS#1{%
-  \TYPE{Main Class: #1}}
-\def\PACKAGE{\@ifnextchar[\OPTPACKAGE\XPACKAGE}
-\def\OPTPACKAGE[#1]#2{%
-  \TYPE{Package: #2^^J\space\space\space\space Options: #1}}
-\def\XPACKAGE#1{%
-  \TYPE{Package: #1}}
-\ifx\@ifnextchar\@undefined
-\long\def\@ifnextchar#1#2#3{%
-  \let\reserved at d=#1%
-  \def\reserved at a{#2}%
-  \def\reserved at b{#3}%
-  \futurelet\@let at token\@ifnch}
-\def\@ifnch{%
-  \ifx\@let at token\@sptoken
-    \let\reserved at c\@xifnch
-  \else
-    \ifx\@let at token\reserved at d
-      \let\reserved at c\reserved at a
+\ifx\InputIfFileExists\@undefined
+  \newread\@inputcheck
+  \long\def\InputIfFileExists#1#2#3{%
+    \openin\@inputcheck#1\relax
+    \ifeof\@inputcheck
+      \def\reserved at a{#3}%
     \else
-      \let\reserved at c\reserved at b
+      \def\reserved at a{#2\input #1\relax}%
     \fi
-  \fi
-  \reserved at c}
-\def\:{\let\@sptoken= } \: % this makes \@sptoken a space token
-\def\:{\@xifnch} \expandafter\def\: {\futurelet\@let at token\@ifnch}
+    \closein\@inputcheck
+    \reserved at a
+  }%
 \fi
-\def\CHECKCOMMAND#1{%
-  \ifx#1\@undefined\LONGTYPEOUT{Undefined \string#1}\else
-  \ifx#1\relax\LONGTYPEOUT{Relaxed \space\space\string#1}\else
-         \LONGTYPEOUT{Defined \space\space\string#1}\fi\fi}
-\ifx\InputIfFileExists\@undefined
-\newread\@inputcheck
-\long\def\InputIfFileExists#1#2#3{%
-  \openin\@inputcheck#1\relax
-  \ifeof\@inputcheck
-    \def\reserved at a{#3}%
-  \else
-    \def\reserved at a{#2\input #1\relax}%
-  \fi
-  \closein\@inputcheck
-  \reserved at a}
-\fi
 \InputIfFileExists{regression-test.cfg}
-      {\LONGTYPEOUT{^^J***^^Jregression-test.cfg in operation^^J***^^J}}{}
-\ifdefined\pdfoutput
-  \ifnum\pdfoutput>0 %
-    \pdfmapfile{pdftex.map}%
-  \fi
-\else
-  \ifdefined\outputmode
-  \ifnum\outputmode>0 %
-    \pdfextension mapfile{pdftex.map}%
-  \fi
-  \fi
-\fi
-\newcount \gTESTint
+  {\LONGTYPEOUT{^^J***^^Jregression-test.cfg in operation^^J***^^J}}{}
+\newcount\gTESTint
 \def\SEPARATOR{%
   \TYPE{%
     ============================================================%
@@ -169,19 +102,19 @@
   }%
 }
 \long\def\TEST#1#2{%
-  \advance \gTESTint 1 %
+  \global\advance\gTESTint by 1 %
   \SEPARATOR
-  \LONGTYPEOUT{%
-    TEST \the\gTESTint: \detokenize{#1}}%
+  \LONGTYPEOUT{TEST \the\gTESTint: \detokenize{#1}}%
   \SEPARATOR
   \begingroup
     \let\TYPE\LONGTYPEOUT
     #2%
   \endgroup
-  \SEPARATOR \LONGTYPEOUT{}%
+  \SEPARATOR
+  \LONGTYPEOUT{}%
 }
 \long\def\TESTEXP#1#2{%
-  \advance \gTESTint 1 %
+  \global\advance\gTESTint by 1 %
   \SEPARATOR
   \LONGTYPEOUT{%
     TEST \the\gTESTint: \detokenize{#1}}%
@@ -198,6 +131,18 @@
 \def \YES   {\TYPE{YES}}
 \def \NO    {\TYPE{NO}}
 \def \NEWLINE {\TYPE{^^J}}
+\ifx\pdfoutput\@undefined
+  \ifx\outputmode\@undefined
+  \else
+    \ifnum\outputmode>0 %
+      \pdfextension mapfile{pdftex.map}%
+    \fi
+  \fi
+\else
+  \ifnum\pdfoutput>0 %
+    \pdfmapfile{pdftex.map}%
+  \fi
+\fi
 \ifnum 0%
   \ifx\pdfoutput\@undefined\else\ifnum\pdfoutput>0 1\fi\fi
   \ifx\outputmode\@undefined\else\ifnum\outputmode>0 1\fi\fi



More information about the tex-live-commits mailing list