> Currently, LilyPond creates a link to the
   > $TEXMF/fonts/tfm/public/cm directory.  Why that?  I can't see a
   > reason for this.  Maybe I'm missing something...

   LilyPond reads the cm TFM files to get spacing information for
   texts.  I don't see any other easy (and obvious to persons with non
   standard TeXs) way to get to those files.

The solution is excellent, but the name of the directory is
unfortunate because `tfm' is a generic name in the TDS-tree.  I
suggest to use `cmtfm' for what you currently call `tfm'.

   >    > What was the reason to remove the --with-texmf-dir option?
   >    > Assuming a TDS conformant TeX tree, no problems should occur
   >    > during installation.
   > 
   >    How can we reliably autodetect the correct directories? That was my
   >    problem.
   > 
   > You can't.  And why should you?

   Because I get approximately 20 e-mails per day about LilyPond.  I want
   the installation to work out without handholding from my part. 

   [...]

   So?  I still have to figure where in this large tree I need to
   read/write files.

I suggest the following procedure *which will work only with a TDS
compliant tree*.  For any other TeX tree layout, automatic
installation is impossible IMHO due to the non-standardized search
paths in kpathsea:

  0.) Install the LilyPond files in /usr/local/share/lilypond as
      usual.  In the following, I call this directory $LILYPOND.  Only
      links are created.

  1.) Search whether e.g. feta11.tex exists (using kpsewhich).  If
      yes, abort the installation so that the people can remove an
      older lilypond package.

  2.) Get the whole $TEXMF path with

        kpsewhich --expand-path=\$TEXMF

  3.) Parse the above directory path until you've found the first
      writeable/readable directory.  In the following, I call this
      directory $MYTEXMF.

  4.) Create links (if necessary, create the parent directories):

        ln -s $LILYPOND/tex $MYTEXMF/tex/lilypond
        ln -s $LILYPOND/ps  $MYTEXMF/dvips/lilypond
        ln -s $LILYPOND/afm $MYTEXMF/fonts/afm/lilypond
        ln -s $LILYPOND/tfm $MYTEXMF/fonts/tfm/public/lilypond
        ln -s $LILYPOND/mf  $MYTEXMF/fonts/source/public/lilypond

  5.) Run either texhash or mktexlsr.


    Werner

Reply via email to