[latex3-commits] [l3svn] 02/03: Build formats for all engines
noreply at latex-project.org
noreply at latex-project.org
Tue Nov 3 12:57:34 CET 2015
This is an automated email from the git hooks/post-receive script.
joseph pushed a commit to branch master
in repository l3svn.
commit 7f42d59c414b374dcafb64b60b54061f2026110b
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date: Tue Nov 3 11:54:09 2015 +0000
Build formats for all engines
---
l3kernel/build.lua | 40 +++++++++++++++++++++++++++++++---------
1 file changed, 31 insertions(+), 9 deletions(-)
diff --git a/l3kernel/build.lua b/l3kernel/build.lua
index 0092220..29294ad 100644
--- a/l3kernel/build.lua
+++ b/l3kernel/build.lua
@@ -11,6 +11,7 @@ maindir = ".."
-- Non-standard settings
checkfiles = {"l3names.def"}
+cleanfiles = {"*.fmt", "*.log", "*.pdf", "*.zip"}
cmdchkfiles = -- Need to miss a few .dtx files
{
-- Missing l3doc, l3fp and subfiles
@@ -65,10 +66,13 @@ end
function format()
local engines = checkengines
- if optengine then
- engines = {optengine}
+ if optengines then
+ engines = optengines
+ end
+ local errorlevel = unpack()
+ if errorlevel ~=0 then
+ return errorlevel
end
- unpack()
os.execute(
-- Set TEXINPUTS to look in the unpack then local dirs only
-- See notes in l3build.lua for unpack ()
@@ -77,15 +81,33 @@ function format()
unpackexe .. " " .. unpackopts .. " -output-directory=" .. unpackdir
.. " " .. unpackdir .. "/" .. "l3format.ins"
)
+ local function mkformat(engine)
+ local realengine = engine
+ -- Special casing for (u)pTeX
+ if string.match(engine, "^u?ptex$") then
+ realengine = "e" .. engine
+ end
+ local errorlevel = run(
+ unpackdir,
+ os_setenv .. " TEXINPUTS=." .. os_concat
+ .. realengine .. " -etex -ini l3format.ltx"
+ )
+ if errorlevel ~=0 then
+ return errorlevel
+ end
+ local fmtname = "l3" .. engine .. ".fmt"
+ ren(unpackdir, "l3format.fmt", fmtname)
+ cp(fmtname, unpackdir, ".")
+ return 0
+ end
local engine
for _,engine in pairs(engines) do
- run(
- unpackdir,
- -- Only look 'here'
- os_setenv .. " TEXINPUTS=." .. os_concat ..
- engine .. " -etex -ini l3format.ltx"
- )
+ errorlevel = mkformat(engine)
+ if errorlevel ~=0 then
+ return errorlevel
+ end
end
+ return 0
end
-- l3kernel does all of the targets itself
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the latex3-commits
mailing list