summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scripts/context/lua/mtxrun.lua19
-rw-r--r--scripts/context/stubs/mswin/mtxrun.lua19
-rwxr-xr-xscripts/context/stubs/unix/mtxrun19
-rw-r--r--tex/context/base/data-pre.lua2
-rw-r--r--tex/context/base/data-res.lua2
-rw-r--r--tex/context/base/data-tmf.lua15
-rw-r--r--tex/context/base/status-files.pdfbin23705 -> 23690 bytes
7 files changed, 56 insertions, 20 deletions
diff --git a/scripts/context/lua/mtxrun.lua b/scripts/context/lua/mtxrun.lua
index 2ec73e932..bc6711e93 100644
--- a/scripts/context/lua/mtxrun.lua
+++ b/scripts/context/lua/mtxrun.lua
@@ -11467,7 +11467,7 @@ local instance = resolvers.instance or nil -- the current one (fast access)
function resolvers.setenv(key,value,raw)
if instance then
-- this one will be consulted first when we stay inside
- -- the current environment
+ -- the current environment (prefixes are not resolved here)
instance.environment[key] = value
-- we feed back into the environment, and as this is used
-- by other applications (via os.execute) we need to make
@@ -12988,6 +12988,8 @@ local cleanpath, findgivenfile, expansion = resolvers.cleanpath, resolvers.findg
local getenv = resolvers.getenv -- we can probably also use resolvers.expansion
local P, Cs, lpegmatch = lpeg.P, lpeg.Cs, lpeg.match
+-- getenv = function(...) return resolvers.getenv(...) end -- needs checking (definitions changes later on)
+
prefixes.environment = function(str)
return cleanpath(expansion(str))
end
@@ -14255,7 +14257,13 @@ function resolvers.load_tree(tree,resolve)
-- Beware, we need to obey the relocatable autoparent so we
-- set TEXMFCNF to its raw value. This is somewhat tricky when
-- we run a mkii job from within. Therefore, in mtxrun, there
- -- is a resolve applied when we're in mkii/kpse mode.
+ -- is a resolve applied when we're in mkii/kpse mode or when
+ -- --resolve is passed to mtxrun. Maybe we should also set the
+ -- local AUTOPARENT etc. although these are alwasy set new.
+
+ if resolve then
+ resolvers.luacnfspec = resolvers.resolve(resolvers.luacnfspec)
+ end
setenv('SELFAUTOPARENT', newroot)
setenv('SELFAUTODIR', newtree)
@@ -14263,11 +14271,12 @@ function resolvers.load_tree(tree,resolve)
setenv('TEXROOT', newroot)
setenv('TEXOS', texos)
setenv('TEXMFOS', texmfos)
- setenv('TEXMFCNF', resolvers.luacnfspec, not resolve)
- setenv("PATH", newpath .. io.pathseparator .. getenv("PATH"))
+ setenv('TEXMFCNF', resolvers.luacnfspec,true) -- already resolved
+ setenv('PATH', newpath .. io.pathseparator .. getenv('PATH'))
report_tds("changing from root '%s' to '%s'",oldroot,newroot)
- report_tds("prepending '%s' to binary path",newpath)
+ report_tds("prepending '%s' to PATH",newpath)
+ report_tds("setting TEXMFCNF to '%s'",resolvers.luacnfspec)
report_tds()
end
end
diff --git a/scripts/context/stubs/mswin/mtxrun.lua b/scripts/context/stubs/mswin/mtxrun.lua
index 2ec73e932..bc6711e93 100644
--- a/scripts/context/stubs/mswin/mtxrun.lua
+++ b/scripts/context/stubs/mswin/mtxrun.lua
@@ -11467,7 +11467,7 @@ local instance = resolvers.instance or nil -- the current one (fast access)
function resolvers.setenv(key,value,raw)
if instance then
-- this one will be consulted first when we stay inside
- -- the current environment
+ -- the current environment (prefixes are not resolved here)
instance.environment[key] = value
-- we feed back into the environment, and as this is used
-- by other applications (via os.execute) we need to make
@@ -12988,6 +12988,8 @@ local cleanpath, findgivenfile, expansion = resolvers.cleanpath, resolvers.findg
local getenv = resolvers.getenv -- we can probably also use resolvers.expansion
local P, Cs, lpegmatch = lpeg.P, lpeg.Cs, lpeg.match
+-- getenv = function(...) return resolvers.getenv(...) end -- needs checking (definitions changes later on)
+
prefixes.environment = function(str)
return cleanpath(expansion(str))
end
@@ -14255,7 +14257,13 @@ function resolvers.load_tree(tree,resolve)
-- Beware, we need to obey the relocatable autoparent so we
-- set TEXMFCNF to its raw value. This is somewhat tricky when
-- we run a mkii job from within. Therefore, in mtxrun, there
- -- is a resolve applied when we're in mkii/kpse mode.
+ -- is a resolve applied when we're in mkii/kpse mode or when
+ -- --resolve is passed to mtxrun. Maybe we should also set the
+ -- local AUTOPARENT etc. although these are alwasy set new.
+
+ if resolve then
+ resolvers.luacnfspec = resolvers.resolve(resolvers.luacnfspec)
+ end
setenv('SELFAUTOPARENT', newroot)
setenv('SELFAUTODIR', newtree)
@@ -14263,11 +14271,12 @@ function resolvers.load_tree(tree,resolve)
setenv('TEXROOT', newroot)
setenv('TEXOS', texos)
setenv('TEXMFOS', texmfos)
- setenv('TEXMFCNF', resolvers.luacnfspec, not resolve)
- setenv("PATH", newpath .. io.pathseparator .. getenv("PATH"))
+ setenv('TEXMFCNF', resolvers.luacnfspec,true) -- already resolved
+ setenv('PATH', newpath .. io.pathseparator .. getenv('PATH'))
report_tds("changing from root '%s' to '%s'",oldroot,newroot)
- report_tds("prepending '%s' to binary path",newpath)
+ report_tds("prepending '%s' to PATH",newpath)
+ report_tds("setting TEXMFCNF to '%s'",resolvers.luacnfspec)
report_tds()
end
end
diff --git a/scripts/context/stubs/unix/mtxrun b/scripts/context/stubs/unix/mtxrun
index 2ec73e932..bc6711e93 100755
--- a/scripts/context/stubs/unix/mtxrun
+++ b/scripts/context/stubs/unix/mtxrun
@@ -11467,7 +11467,7 @@ local instance = resolvers.instance or nil -- the current one (fast access)
function resolvers.setenv(key,value,raw)
if instance then
-- this one will be consulted first when we stay inside
- -- the current environment
+ -- the current environment (prefixes are not resolved here)
instance.environment[key] = value
-- we feed back into the environment, and as this is used
-- by other applications (via os.execute) we need to make
@@ -12988,6 +12988,8 @@ local cleanpath, findgivenfile, expansion = resolvers.cleanpath, resolvers.findg
local getenv = resolvers.getenv -- we can probably also use resolvers.expansion
local P, Cs, lpegmatch = lpeg.P, lpeg.Cs, lpeg.match
+-- getenv = function(...) return resolvers.getenv(...) end -- needs checking (definitions changes later on)
+
prefixes.environment = function(str)
return cleanpath(expansion(str))
end
@@ -14255,7 +14257,13 @@ function resolvers.load_tree(tree,resolve)
-- Beware, we need to obey the relocatable autoparent so we
-- set TEXMFCNF to its raw value. This is somewhat tricky when
-- we run a mkii job from within. Therefore, in mtxrun, there
- -- is a resolve applied when we're in mkii/kpse mode.
+ -- is a resolve applied when we're in mkii/kpse mode or when
+ -- --resolve is passed to mtxrun. Maybe we should also set the
+ -- local AUTOPARENT etc. although these are alwasy set new.
+
+ if resolve then
+ resolvers.luacnfspec = resolvers.resolve(resolvers.luacnfspec)
+ end
setenv('SELFAUTOPARENT', newroot)
setenv('SELFAUTODIR', newtree)
@@ -14263,11 +14271,12 @@ function resolvers.load_tree(tree,resolve)
setenv('TEXROOT', newroot)
setenv('TEXOS', texos)
setenv('TEXMFOS', texmfos)
- setenv('TEXMFCNF', resolvers.luacnfspec, not resolve)
- setenv("PATH", newpath .. io.pathseparator .. getenv("PATH"))
+ setenv('TEXMFCNF', resolvers.luacnfspec,true) -- already resolved
+ setenv('PATH', newpath .. io.pathseparator .. getenv('PATH'))
report_tds("changing from root '%s' to '%s'",oldroot,newroot)
- report_tds("prepending '%s' to binary path",newpath)
+ report_tds("prepending '%s' to PATH",newpath)
+ report_tds("setting TEXMFCNF to '%s'",resolvers.luacnfspec)
report_tds()
end
end
diff --git a/tex/context/base/data-pre.lua b/tex/context/base/data-pre.lua
index fa3588c6e..4a5f0ecf5 100644
--- a/tex/context/base/data-pre.lua
+++ b/tex/context/base/data-pre.lua
@@ -24,6 +24,8 @@ local cleanpath, findgivenfile, expansion = resolvers.cleanpath, resolvers.findg
local getenv = resolvers.getenv -- we can probably also use resolvers.expansion
local P, Cs, lpegmatch = lpeg.P, lpeg.Cs, lpeg.match
+-- getenv = function(...) return resolvers.getenv(...) end -- needs checking (definitions changes later on)
+
prefixes.environment = function(str)
return cleanpath(expansion(str))
end
diff --git a/tex/context/base/data-res.lua b/tex/context/base/data-res.lua
index 773f7d58e..4d48c3027 100644
--- a/tex/context/base/data-res.lua
+++ b/tex/context/base/data-res.lua
@@ -136,7 +136,7 @@ local instance = resolvers.instance or nil -- the current one (fast access)
function resolvers.setenv(key,value,raw)
if instance then
-- this one will be consulted first when we stay inside
- -- the current environment
+ -- the current environment (prefixes are not resolved here)
instance.environment[key] = value
-- we feed back into the environment, and as this is used
-- by other applications (via os.execute) we need to make
diff --git a/tex/context/base/data-tmf.lua b/tex/context/base/data-tmf.lua
index 9391e881e..260beb9f4 100644
--- a/tex/context/base/data-tmf.lua
+++ b/tex/context/base/data-tmf.lua
@@ -47,7 +47,13 @@ function resolvers.load_tree(tree,resolve)
-- Beware, we need to obey the relocatable autoparent so we
-- set TEXMFCNF to its raw value. This is somewhat tricky when
-- we run a mkii job from within. Therefore, in mtxrun, there
- -- is a resolve applied when we're in mkii/kpse mode.
+ -- is a resolve applied when we're in mkii/kpse mode or when
+ -- --resolve is passed to mtxrun. Maybe we should also set the
+ -- local AUTOPARENT etc. although these are alwasy set new.
+
+ if resolve then
+ resolvers.luacnfspec = resolvers.resolve(resolvers.luacnfspec)
+ end
setenv('SELFAUTOPARENT', newroot)
setenv('SELFAUTODIR', newtree)
@@ -55,11 +61,12 @@ function resolvers.load_tree(tree,resolve)
setenv('TEXROOT', newroot)
setenv('TEXOS', texos)
setenv('TEXMFOS', texmfos)
- setenv('TEXMFCNF', resolvers.luacnfspec, not resolve)
- setenv("PATH", newpath .. io.pathseparator .. getenv("PATH"))
+ setenv('TEXMFCNF', resolvers.luacnfspec,true) -- already resolved
+ setenv('PATH', newpath .. io.pathseparator .. getenv('PATH'))
report_tds("changing from root '%s' to '%s'",oldroot,newroot)
- report_tds("prepending '%s' to binary path",newpath)
+ report_tds("prepending '%s' to PATH",newpath)
+ report_tds("setting TEXMFCNF to '%s'",resolvers.luacnfspec)
report_tds()
end
end
diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf
index 35f00b308..990387a72 100644
--- a/tex/context/base/status-files.pdf
+++ b/tex/context/base/status-files.pdf
Binary files differ