diff options
author | Marius <mariausol@gmail.com> | 2013-01-14 00:20:22 +0200 |
---|---|---|
committer | Marius <mariausol@gmail.com> | 2013-01-14 00:20:22 +0200 |
commit | fe55ae49d8deddeb8f02557e3902c847804b0086 (patch) | |
tree | e7d92e04f7acaf2773c23ea081c4d2fe0dc0a167 /scripts/context/lua/mtx-context.lua | |
parent | d38d94fe9542984e38b9839eb2383656328b9da9 (diff) | |
download | context-fe55ae49d8deddeb8f02557e3902c847804b0086.tar.gz |
beta 2013.01.13 23:10
Diffstat (limited to 'scripts/context/lua/mtx-context.lua')
-rw-r--r-- | scripts/context/lua/mtx-context.lua | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/scripts/context/lua/mtx-context.lua b/scripts/context/lua/mtx-context.lua index e4b5fb302..e3aac141f 100644 --- a/scripts/context/lua/mtx-context.lua +++ b/scripts/context/lua/mtx-context.lua @@ -138,6 +138,7 @@ local application = logs.application { -- ["version"] = true, -- display version and exit -- ["luaonly"] = true, -- run a lua file, then exit -- ["luaconly"] = true, -- byte-compile a lua file, then exit +-- ["jiton"] = false, -- } local report = application.report @@ -147,6 +148,12 @@ scripts.context = scripts.context or { } -- for the moment here +if getargument("jit") then + -- bonus shortcut, we assume than --jit also indicates the engine + -- although --jit and --engine=luajittex are independent + setargument("engine","luajittex") +end + local engine_new = getargument("engine") or directives.value("system.engine") local engine_old = environment.ownbin @@ -656,7 +663,7 @@ function scripts.context.run(ctxdata,filename) ["fmt"] = formatfile, ["lua"] = scriptfile, ["jobname"] = jobname, - ["jiton"] = a_jit and true or nil, + ["jiton"] = a_jit and true or false, } -- if a_synctex then @@ -845,7 +852,7 @@ function scripts.context.pipe() -- still used? end local function make_mkiv_format(name,engine) - environment.make_format(name) + environment.make_format(name) -- jit is picked up later end local function make_mkii_format(name,engine) @@ -866,6 +873,9 @@ function scripts.context.make(name) end local list = (name and { name }) or (environment.files[1] and environment.files) or defaultformats local engine = getargument("engine") or "luatex" + if getargument("jit") then + engine = "luajittex" + end for i=1,#list do local name = list[i] name = formatofinterface[name] or name or "" |