Sanjoy Mahajan wrote: > Here's what I had to do to update to the latest Context (2006.07.14) on > Ubuntu 6.06 (i.e. 2006.06) distribution of Linux. It comes with tetex > 3.0. The commands below assume a working Context already installed in > your ~/texmf, and the commands use bash syntax, which is almost like > 'sh' but has the ~ idiom for $HOME.
Updating context was one of the things on my todo list. great. > > Beforehand I had been using the 2006.04.17 beta and had put off > upgrading because I was scared of the change from perl texexec to ruby > texexec. > > 1. (optional cleanup) Delete the old Context-installed files in > ~/texmf/. This step is optional, but I do it so that I can track the > versions using an SCM. I use mercurial (hg is the program name), but > it could have been svn, cvs, etc. The command (done in ~/texmf): > > hg locate -0 | xargs rm -0 > > 2. (download, unpack) Download cont-tmf.zip, cont-fnt.zip, and > cont-img.zip. Probably you need only the first zip file, but I'm > reporting exactly what I did just in case any substep is the crucial > one. The command: > > cd /tmp/ # no need to save them long-term > wget http://www.pragma-ade.nl/context/current/cont-{tmf,fnt,img}.zip > > Unzip the zip archives into ~/texmf, appending the giant > list of files to /tmp/a.log: > > cd ~/texmf > for f in /tmp/cont-{tmf,fnt,img}.zip ; do unzip $f >> /tmp/a.log ;done > > 3. (stubs, part 1) Create ~/bin/texmfstart containing two lines: > > #!/bin/bash > ~/texmf/scripts/context/ruby/texmfstart.rb "$@" > > Then make it executable with > > chmod +x ~/bin/texmfstart > > From what I can tell from reading the ruby code, using the full path > to texmfstart.rb helps texmfstart.rb find the other .rb programs, > like texexec.rb. (texmfstart.rb uses the path it was called with and > looks in that directory, but Hans can correct me if I'm wrong here.) > > 4. (stubs, part 2) texmfstart will run texexec, so create texexec as a > symlink to ~/texmf/scripts/context/stubs/unix/texexec: > > cd ~/bin > ln -s ~/texmf/scripts/context/stubs/unix/texexec > chmod +x texexec > > Hans: Could texexec be made executable in the distribution's zip > file, to avoid the chmod? > > 5. (test 1) A first check is that texexec works. So change to a random > directory, e.g. where you keep some Context files: > > cd ~/tmp/xy ; texexec --version > > That produces: > > TeXExec | version 6.2.0 - 1997-2006 - PRAGMA ADE/POD > > which looks good > > 6. (formats) Remake the formats with > > texexec --make --all until here everything seems to work... > > 7. (test 2) Try a simple file. I use ~/tmp/xy/t.tex containing one > line, "\starttext abc \stoptext". Here goes: > > texexec t > > fails with > > ! Font \*12ptrmtf*=ec-lmr12 not loadable: Metric (TFM) file not found. on my machine this fails with: $ texexec t.tex TeXExec | processing document 't.tex' TeXExec | no ctx file found TeXExec | tex processing method: context TeXExec | TeX run 1 TeXExec | writing option file t.top TeXExec | using randomseed 1062 TeXExec | tex engine: pdfetex TeXExec | tex format: cont-en TeXExec | progname: context This is pdfeTeX, Version 3.141592-1.21a-2.2 (Web2C 7.5.4) (/home/ralf/texmf/web2c/natural.tcx) entering extended mode (./t.tex ConTeXt ver: 2005.01.31 fmt: 2006.6.27 int: english mes: english language : language en is active <protectionstate 0> system : cont-new loaded (/home/ralf/texmf/tex/context/base/cont-new.tex ! Undefined control sequence. l.14 \newcontextversion {2006.07.24 10:49} ? ! Emergency stop. l.14 \newcontextversion {2006.07.24 10:49} No pages of output. Transcript written on t.log. TeXExec | runtime: 1.705616 Any Ideas? > > 8. (dreaded lmodern) Ack, it's the dreaded lmodern problem. I thought I > had avoided this issue on my previous laptop, which ran Debian > testing/unstable and got reincarnated as an Ubuntu laptop. And I had > fixed it, by installing the 'lmodern' package. But Ubuntu lmodern is > v0.92, at least as of Ubuntu 6.06, and Debian unstable uses v1.00, > which includes the necessary .tfm files for ec-lmr*. The beta Ubuntu > ('edgy eft') uses the new version, so I downloaded its .deb via > http://packages.ubuntu.com, which eventually pointed me to a monster > url and I did: > > cd /tmp > wget > http://ubuntu.mirrors.tds.net/ubuntu/pool/universe/l/lmodern/lmodern_1.00-2_all.deb > > Note that the package version may change, so the easiest way is to > download the latest .deb from > http://ubuntu.mirrors.tds.net/ubuntu/pool/universe/l/lmodern/ > > Installing it is a bit painful. The first try (done as root) of > > dpkg -i /tmp/lmodern_1.00-2_all.deb > > complains with > > Usage error: unrecognized option > Usage: update-fonts-dir DIRECTORY ... > > 'update-fonts-dir' is some X program that updates X's ideas of where > its fonts are, and the package isn't calling it correctly. But I > don't care whether X knows about the lmodern fonts, since I'm using > them for documents viewed with gv or xpdf, not directly as an X font. > So I shut up update-fonts-dir for the moment, installed, and undid > the shutting up (all as root): > > chmod -x /usr/bin/update-fonts-dir > dpkg -i /tmp/lmodern_1.00-2_all.deb > chmod +x /usr/bin/update-fonts-dir > > 9. (test 2 again, not as root) Now 'texexec t' works fine, as does > 'texexec --check' > > So I think all is well, and I didn't need to set RUBYLIB. Let me know > of any corrections or improvements; if there's interest I'll wikifi. > >>From now on, I hope I can update using > > texmfstart ctxtools --updatecontext > does not work for me: $ texmfstart ctxtools --updatecontext kpsewhich: option `--expand-var' requires an argument CtxTools | updating CtxTools | unable to change to > -Sanjoy > _______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context