On Fri, 22 Jan 2010, Gour wrote:
On Fri, 22 Jan 2010 12:59:39 +0100
> "Hans" == Hans Hagen
wrote: Hans> if you download the minimals installer script from the garden and Hans> run Hans> Hans> ./first-update.sh --engine=luatex
Hmm, the build script does not run first-update.sh but it invokes the following:
... msg "Starting download or update of ConTeXt distribution" $srcdir/bin/texlua $srcdir/bin/mtxrun --script $srcdir/bin/mtx-update.lua \ --platform=$_platform --texroot=$srcdir/tex --engine=all --extras=all \ --context=beta --update --force || return 1
Maybe I should wait for Aditya to explain what is he doing...
This is the best compromise I could get for running MkIV in a multi-user environment. I do not ask the mtx-update script to generate the formats (the --make flag is missing), because this script is running as root. Generating the formats means that luatex-cache will be generated by root, and then a user will never be able to writing anything in the cache directory. So, I do not generate the formats during the update. In the post-install
post_install() { source /opt/context-minimals/setuptex mktexlsr texexec --make cont-en metafun texexec --make --xetex echo "*************************************************************" echo "To use ConTeXt minimals run" echo ". /opt/context-minimals/setuptex" echo "To use MkIV run" echo "luatools --generate" echo "*************************************************************" }
I generate the pdftex and xetex formats, and ask the user to run luatools --generate. When run for the first time, luatools --generate creates the $TEXMFCACHE directory. Since the command is run by the user, TEXMFCACHE is writable by the user. Once luatools --generate is run, you can simply run "context filename". ConTeXt sees that the formats are wrong and regenerates them on the fly. The first luatools --generate is needed so that mtxrun can find the mtx-context script. (context is just a wrapper around mtx-context.lua). Currently something is going wrong in the installation script. Others have said that you need to "press enter twice" to get it to run. My guess is that something is trying to generate the luatools format, even though I have not asked for it. I will investigate further why this is happening. Aditya