[NTG-context] wiki: debian installation

plink plink at nectarine.info
Mon Oct 2 22:29:41 CEST 2006


> That's too vague to be helpful.  Having written some of the Debian
> installation materials, I would find it useful to know what places
> were wrong or misleading so that it could be improved.

Good to hear this part of the ConTeXt labyrinth still has some care 
taking inhabitants ...

So, here are some specifics about the experiences following the wiki
installation page for Debian. It reminds me of catching a young koetje 
with too many efforts, and just when you are about to give up, the thing 
is already in the barn.

First of all, why the page is rather misleading:

* In the beginning the installation text seems to intend a global
   installation of ConTeXt, but later on it silently switches towards a
   user specific one. Latter is fine with me, but do we really have to
   change the system-wide TeX installation for that?

* The system-wide installation is changed without using the debian
   package system at all. If there is a reason for this, it is not
   mentioned in the text.
   Besides, the wiki link to this page says that the installation is
   intended for people who like to use apt. Well, quite the contrary:
   this installation procedure is for people who *dont* want to use apt
   for their context installation, because ConTeXt is installed across
   different parts of the debian package system, apt is just used to
   get some general TeX/tetex-packages.
   I won't go into details here WhyThisIsNotAGoodThing, if it´s all about
   a box intended for "Personal ConTeXing" it might be o.k., but
   most certainly not for a box that hosts different users and
   TeX flavors, so that it could use a single management interface like
   the debian one.

* In the end, debian works out perfectly well now, as shown below. Plus
   there is a more debianish way to have a system-wide fresh ConTeXt
   koetje on your box every other release day (s. below).

Ok, so much for generics. Now lets go along the installation text and
see what happens on a fresh debian (unstable release 2006-10-02) system:

1. First we make sure to have packages tetex-bin, tetex-extra, lmodern
    and cm-super and install the new metapost and pdftex versions by
    hand.

2. What now? Ok, now we are switching to a user specific installation.
    Where? Any pathname restrictions? The text doesn´t mention
    anything, but lets call it ~myuser/texmf, just to be on the safe
    side. A lot of people may never have heard about TEXMFHOME
    environment variables. It could be helpful to mention it at this
    point.

3. we download and unzip cont-tmf.zip and then at the end of
       ~myuser/texmf > texexec --make

       ... lots of output ...

       used engineformatpath : /home/myuser/texmf/web2c/pdfetex/
                  TeX binary : pdfetex
                   format(s) : en nl metafun mptopdf
              total run time : 4 seconds
                     warning : use 'texmfstart texexec' instead

    Hmm. A warning. Do we have to care? Anyway, lets continue.

4. What now, pt. 2: the big heading says "Context first time upgrade",
    but the small text a few lines above says
        "If you have already followed the *following* steps"
    (my emphasis) which seems a little odd to some non-native speakers,
    if they notice that fine point anyway: it doesnt say previous
    steps, it says following steps, the steps we haven´t read so far ...

    After some ruminations it seems we just have two alternatives here:
       if you follow these instructions the first time,
             please do the following
       if you just want to upgrade cont-tmf,
             please go to chapter foobar

    Alright, so we´re doing a "first time upgrade", since we´re
    following these instructions the first time and have an old ConTeXt
    in the standard debian tetex package. According to the text we should
    look out for old formats. No search results in any user
    dot-directory.
    Our last step generated cont-en, cont-nl and mptopdf format files in
       ~myuser/texmf/web2c/pdfetex/
    "kpsewhich cont-en.fmt" does only return the global format we created
    during the pdfetex installation in step 1. Even a
       # find / -iname cont-en.fmt
    returns nothing more. This step seems finished, now we tell TeX how
    to find our formats in the next step by changing the configlets.

5. First, according to the wiki, we need to comment out the format
    generation of mptopdf, metafun and cont-en, which is controlled by
    /etc/texmf/fmt.d/01tetex.cnf (we notice that there is no metafun
    format in our local directory,  but maybe thats intentional).
    We run update-fmtutil. Still just the old metafun.mem in
    /var/lib/texmf/web2c, what to do about this? No instructions, so
    lets just leave it at that, and add the {$engine,} subpath string
    to TEXFORMATS, followed by an update-texmf.

6. Everythings o.k. now? Let´s see:
       ~myuser/ > texexec --version
       TeXExec 5.4.3 - ConTeXt / PRAGMA ADE 1997-2005

                texexec : TeXExec 5.4.3 - ConTeXt / PRAGMA ADE 1997-2005
                texutil : TeXUtil 9.0.1 - ConTeXt / PRAGMA ADE 1992-2006
                    tex : pdfeTeX, 3.141592-1.30.6-2.2 (Web2C 7.5.5)
                context : ver: 2006.08.08 21:51
                cont-en : ver: 2006.08.08 21:51  fmt: 2006.9.30  mes:
                                                                  english

         total run time : 0 seconds
                warning : use 'texmfstart texexec' instead

    Hmm. Again the warning. What is this texmfstart thing anyway? In
       ~myuser/scripts/context/ruby/texmfstart.rb
       ~myuser/scripts/context/stubs/lib/texmfstart
    there is something, but maybe it is not (yet?) needed. So let´s give
    it a try and create the first "official" ConTeXt test file hello.tex:
       \starttext
       Hello World
       \stoptext
    and then:
       ~myuser/ > texexec --pdf hello.tex
       ...
       ... lots of output that looks o.k., until:
       ...
       fonts           : using map file:original-public-lm(/home/myuser
       /texmf/tex/context/base/pdfr-ec.tex)[1.1{/home/myuser/texmf/fonts
       /map/dvipdfm/context/original-empty.map}{/home/myuser/texmf/fonts
       /map/dvipdfm/context/texnansi-public-lm.map}{/home/myuser/texmf
       /fonts/map/dvipdfm/context/original-base.map
       Warning: pdfetex (file /home/myuser/texmf/fonts/map/dvipdfm/
       context/original-base.map): invalid entry for `fmvr8x': font file
       missing
       ...
       ... and a lot more of these warnings follow, also in the 2nd run:
       ...
       Warning: pdfetex (file/home/myuser/texmf/fonts/map/dvipdfm/context
       /original-public-lm.map): invalid entry for `cmmib9': font file
       missing}]
       systems         : end file hello at line 3
       )
       Output written on hello.pdf (1 page, 2611 bytes).
       Transcript written on hello.log.

                  return code : 0
                     run time : 0 seconds
         sorting and checking : running texutil
        TeXUtil 9.0.1 - ConTeXt / PRAGMA ADE 1992-2006
                       action : processing commands, lists and registers
                       option : sorting IJ under Y
                       option : converting high ASCII values
                   input file : hello.tui
                  output file : hello.tuo
              passed commands : 19
                remapped keys : 0
             register entries : 1 -> 0 entries 0 references       synonym
        entries : 3 -> 1 entries
                  bad entries : 3
               embedded files : 1
                       remark : 'texutil' is now part of 'texexec'
                      warning : use 'texmfstart texutil' instead
               total run time : 1 seconds
                      warning : use 'texmfstart texexec' instead

    Hmm. The texmfstart warning looks familiar, but missing font
    files? Strange. Anyway, the pdf-file looks ok, so lets be more
    adventurous, and try the second ConTeXt test file from the wiki,
    the one with the little red hat:
       texexec --pdf littleredhat.tex
        TeXExec 5.4.3 - ConTeXt / PRAGMA ADE 1997-2005
       fixing engine variable : pdfetex
                    executable : pdfetex
                        format : cont-en
                     inputfile : littleredhat
                        output : pdftex
                     interface : en
                  current mode : none
                       TeX run : 1
       This is pdfeTeX, Version 3.141592-1.30.6-2.2 (Web2C 7.5.5)
        (/home/myuser/texmf/web2c/natural.tcx)
       entering extended mode
       (./littleredhat.tex
       ConTeXt  ver: 2006.08.08 21:51  fmt: 2006.9.30  int: english  mes:
       english
       language        : language en is active
       <protectionstate 0>
       system          : cont-new loaded
       (/home/myuser/texmf/tex/context/base/cont-new.tex
       systems         : beware: some patches loaded from cont-new.tex
       color           : palette rollover is available
       )

       ... and then:

       systems         : system commands are disabled
       encoding        : unknown coding il15
       (./littleredhat.tuo) (./littleredhat.tuo) (./littleredhat.tuo)
       (./littleredhat.tuo) (./littleredhat.tuo)(./littleredhat.tuo)
       (./littleredhat.tuo) (./littleredhat.tuo) (./littleredhat.tuo)
       (./littleredhat.tuo)(/home/myuser/texmf/tex/context/base/sort-de
       f.tex)(/home/myuser/texmf/tex/context/base/sort-lan.tex)(./little
       redhat.tuo) (./littleredhat.tuo)
       systems         : begin file littleredhat at line 4
       (/home/myuser/texmf/tex/context/base/pdfr-ec.tex)
       fonts           : resetting map file list
       fonts           : using map file: texnansi-public-lm
       fonts           : using map file: original-base
       fonts           : using map file: ec-public-lm
       fonts           : using map file: ec-base
       fonts           : using map file: 8r-base
       fonts           : using map file: t5-base
       fonts           : using map file: original-ams-base
       fonts           : using map file: original-ams-euler
       fonts           : using map file: original-public-lm
       [1.1{/home/myuser/texmf/fonts/map/dvipdfm/context/original-empty
       .map}{/home/myuser/texmf/fonts/map/dvipdfm/context/texnansi-
       public-lm.map}{/home/myuser/texmf/fonts/map/dvipdfm/context
       /original-base.map
       Warning: pdfetex (file /home/myuser/texmf/fonts/map/dvipdfm/
       context/original-base.map): invalid entry for `fmvr8x': font
       file missing
       Warning: pdfetex (file /home/myuser/texmf/fonts/map/dvipdfm/
       context/original-base.map): invalid entry for `xycmat11': font
       file missing

       ... lots of font file missing errors, until:

       Warning: pdfetex (file /home/myuser/texmf/fonts/map/dvipdfm/
       context/original-public-lm.map): invalid entry for `cmmib9': font
       file missing}]
       systems         : end file littleredhat at line 11
       )
       Output written on littleredhat.pdf (1 page, 3637 bytes).
       Transcript written on littleredhat.log.

                  return code : 0
                     run time : 0 seconds
         sorting and checking : running texutil
        TeXUtil 9.0.1 - ConTeXt / PRAGMA ADE 1992-2006
                       action : processing commands, lists and registers
                       option : sorting IJ under Y
                       option : converting high ASCII values
                   input file : littleredhat.tui
                  output file : littleredhat.tuo
              passed commands : 19
                remapped keys : 0
             register entries : 1 -> 0 entries 0 references
              synonym entries : 3 -> 1 entries
                  bad entries : 3
               embedded files : 1
                       remark : 'texutil' is now part of 'texexec'
                      warning : use 'texmfstart texutil' instead
               total run time : 0 seconds
                      warning : use 'texmfstart texexec' instead

    So the same font warnings again, but arggh - this time we really
    have a problem: the pdf doesn´t contain a single umlaut. And this
    seems to be the end of the story. Now got really stuck, regime
    changes, encoding changes, mktexlsr, nothing helps.

Conclusion: following the instructions doesnt lead to a working ConTeXt 
system for a single user. But does he need these sidewide config changes 
anyway?

Look what texconfig is doing for our user if he pushes it to
format creation e.g. by setting page size:
Start of output:
       texconfig: updated configuration saved as file
       `/home/myuser/.texmf-config/dvips/config/config.ps'texconfig:
       updated configuration saved as file
       `/home/myuser/.texmf-config/dvipdfm/config/config'
       texconfig: updated configuration saved as file
       `/home/myuser/.texmf-config/xdvi/XDvi'
       texconfig: updated configuration saved as file
       `/home/myuser/.texmf-config/tex/generic/config/pdftexconfig.tex'

       fmtutil: running `mf -ini   -jobname=mf -progname=mf
       -translate-file=cp227.tcx mf.ini' ...
       This is METAFONT, Version 2.71828 (Web2C 7.5.4) (INIMF)
       (/usr/share/texmf-tetex/web2c/cp227.tcx)
       (/usr/share/texmf-tetex/metafont/config/mf.ini
       (/usr/share/texmf-tetex/metafont/base/plain.mf

       ... lots of output, but see:

       fmtutil: running `pdfetex -ini   -jobname=cont-en
       -progname=context -translate-file=cp227.tcx *cont-en.ini' ...
       This is pdfeTeX, Version 3.141592-1.30.6-2.2 (Web2C 7.5.5)
       (INITEX)(/usr/share/texmf-tetex/web2c/cp227.tcx)
       entering extended mode
       (/home/myuser/texmf/tex/context/config/cont-en.ini
       (/home/myuser/texmf/tex/context/base/cont-en.tex
       (/home/myuser/texmf/tex/context/base/context.tex
       (/home/myuser/texmf/tex/context/base/syst-pln.tex)
       (/home/myuser/texmf/tex/context/base/syst-prm.tex)
       (/home/myuser/texmf/tex/context/base/syst-etx.tex)
       (/home/myuser/texmf/tex/context/base/syst-omg.tex)
       (/home/myuser/texmf/tex/context/base/syst-xtx.tex)
       (/home/myuser/texmf/tex/context/base/syst-gen.tex
       loading         : Context System Macros / General
       ) (/home/myuser/texmf/tex/context/base/syst-ext.tex
       loading         : Context System Macro's / Extras

       ... again lots of output, but also here:

       fmtutil: running `pdfetex -ini   -jobname=mptopdf
       -progname=context -translate-file=cp227.tcx mptopdf.tex' ...
       This is pdfeTeX, Version 3.141592-1.30.6-2.2 (Web2C 7.5.5)
       (INITEX)(/usr/share/texmf-tetex/web2c/cp227.tcx)
       (/home/myuser/texmf/tex/generic/context/mptopdf.tex
       (/home/myuser/texmf/tex/context/base/syst-tex.tex
       (/usr/share/texmf-tetex/tex/plain/base/plain.tex
       Preloading the plain format: codes, registers, parameters, fonts,
       skipping \font in plain
       ...

and in the end writes all the format files into
~myuser/.texmf-var/web2c. So: nothing wrong here, texconfig does exactly 
what it should and creates the formats with respect to the users 
TEXMFHOME. That way the user is capable of using his own context version 
without the need to care about the system-wide context version.

But what about a system-wide ConTeXt refresh? For a ConTeXt layperson 
like me this seems simple: just use TEXMFLOCAL, as it is laid out in the 
debian TeX policy. In short: LOCAL shadows DIST and MAIN. Here is a 
little scriptlet that works on a clean unstable system without the 
changes mentioned above:

       # mkdir /usr/local/share/texmf
       # cd /usr/local/share/texmf
       # unzip /path/to/fresh/cont-tmf.zip
       # chmod 755 scripts/context/ruby/texmfstart.rb
       # texexec --make
       # mv conte-en.fmt cont-nl.fmt metafun.mem mptopdf.fmt web2c/
       # texhash

That´s it. Now the system generates format files using the new ConTeXt 
version. No other changes to /etc/texmf needed. Why the chmod? Well, 
this is part of the solution of the encoding/umlaut problems.
What about it?
Well, several hours of documentation/wiki grinding later we thought: 
lets do it like the ConTeXt gurus and try the texmfstart thing. We 
created the two liner /home/myuser/bin/texexec:

       #!/bin/sh
       texmfstart texexec.rb --nonstopmode "$@"

and a link

       ln -s ~/texmf/scripts/context/ruby/texmfstart.rb texmfstart

Heureka - that was it! Umlauts, special chars in typing environments
etc. are fine with the new texexec, even if the system wide format
files are created with the old texexec !?!

hth and wel te rusten,
Jak.

PS: One question remains:
is the texmfstart.rb way now the "official" way of doing ConTeXt on
Linux/Debian these days? If so, it´d better be documented for the
rookies of us somehow/somewhere, if not, something else in the
documentation needs to be fixed.

PPS: No, still no idea who should write all that documentation.





















.


--------------------------------------------------------------------
150MB of disk space, Webmail over SSL with address book, calendar, 
and organizer. Access thru Imap, Imap-SSL, Pop3, Pop3-SSL and Smtp. 
5 different domains, antispam (spamassassin, bayes, razor, dcc) and mime filter,

Up to 200mb per outgoing message.
All free, is your current email having this functionalities ?
Check http://www.nemail.it for registration and more info.

This message is added automatically, for any information or support 
contact: support at nectarine.info; if it is spam dont hesitate to report it.
-------------------------------------------------------------------- 


More information about the ntg-context mailing list