[dev-context] integrating context mkiv, luatex, and fmtutil, mktexlsr, etc

Hans Hagen pragma at wxs.nl
Wed Oct 3 12:25:22 CEST 2007

Norbert Preining wrote:

> I am starting to think about integrating context/mkiv/luatex into TeX
> Live (and use as a test bed the Debian packages). Currently I see the
> following problems:
> - integration into fmtutil:
>   currently we build formats for cont-en/xetex, cont-en/pdftex, etc
>   based on the fmtutil.cnf syntax, ie calling something like
> 	$ENGINE -ini  -jobname=cont-en -progname=context -8bit *cont-en.ini
>   Now putting luatex as engine this doesn't work:
> (/usr/share/texmf/tex/context/base/luat-env.tex
> ! LuaTeX error [string "luas[0]"]:1: attempt to index global 'input' (a nil value).
> <argument> ...mf.instance,"luat-env.lua","tex")) }

that won't work because luatex by itself cannot take care of the stubs 
it may need for starting up (how could it know -)

making a format (at least formkiv, but also for plain if you want) 
boils down to:

- making a lua stub file (lua)
- compiling that for fast loading (luc)
- making a format

the stub is needed because the first thing that we do is to overload 
kpse (and provide support for reading from zips etc); the stub is later 
overloaded by embedded code if needed; luatools takes care of making the 
stub, compiling it etc etc

$ENGINE --luaonly luatools.lua --make --compile cont-en
$ENGINE --luaonly luatools.lua --make --compile plain

> - integration into mktexlsr
>   see my other email about multiple cache merging, but to some up:
>   . cache should be read from more then one directory, eg from
>     TEXMFSYSCACHE and TEXMFCACHE (with usual override stuff)
>   . single cache updates should be possible:
> 	luatools --generate $HOME/texmf

i'll see what i can do

>     should generate the cache for $HOME/texmf in $TEXMFCACHE

what exactly do you mean with integration? calling luatools?

> Other things I realized as user:
> - running texexec --lua test.tex generates the format in 
> 	~/luatex-cache/context/e027248d6557d124c703335e8a95ecd5/formats
>   but it creates it again and again. 

strange, since texexec --lua is not supposed to generate a format at all

> - If I move the generated files from the above dir to
> 	~/.texmf-var/web2c/luatex/
>   and regenerate the luatex-cache with --generate --verbose the next run 
>   does not work:

(i wonder what i do with the . in .texmf-var -)

the cache is not hashed (no reason for doing it)

> LuaTools | using format name /home/norbert/luatex-cache/context/e027248d6557d124c703335e8a95ecd5/formats/cont-en.fmt
> LuaTools | no luc/lua with name /home/norbert/luatex-cache/context/e027248d6557d124c703335e8a95ecd5/formats/cont-en


                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl

More information about the dev-context mailing list