<?xml version="1.0"?> 
<!DOCTYPE TEI.2 SYSTEM 
"/P4/TEI/web/Software/tei-emacs/xml/dtds/tei/tei-oucs.dtd" []>
<TEI.2>
 <teiHeader>
  <fileDesc>
   <titleStmt>
    <title>The Occult Secrets of TeXLive</title>
    <author>Sebastian Rahtz and Fabrice Popineau</author>
   </titleStmt>
   <publicationStmt>
     <p>Dante 2003</p>
   </publicationStmt>
   <sourceDesc>
    <p>Composed in a hotel in Bremen</p>
   </sourceDesc>
  </fileDesc>
 </teiHeader>
 <text>
<front>
<docTitle> 
  <titlePart type="main">The Occult Secrets of TeXLive</titlePart> 
</docTitle> 
<docAuthor>Sebastian Rahtz and Fabrice Popineau</docAuthor> 
<docDate>April 2003</docDate> 
 </front> 
  <body>
<div rend="slide">
<head>Overview of TeX Live</head>
<p>TeX Live is a multiple-platform distribution of TeX on CD,
coming up to its yearly 8th edition
<list>
<item>Started from a working party in 1993, which went
nowhere, but stimulated the production of the great 4AllTeX 
DOS-based distribution, and the TDS standard</item>
<item>Work on TL started in late 1995, and the first edition came
out in spring 1996</item>
<item>Initially Unix/Linux only. Basically, it is Esser's teTeX</item>
<item>Joined by Windows in 4th edition</item>
<item>Joined by MacOSX in 7th edition</item>
<item>Since the 5th edition, has aimed to be compliant with the 
Debian Free Software Guidelines</item>
     </list>
    </p>
   </div>

<div rend="slide">
<head>Heroes (no villains)</head>
<p><list>
<item>DANTE e.V., who provide the master server
       (run by Reinhard Zierke and Rainer Schöpf)</item>
<item>The Perforce company, who give us a free license for the change
       management software</item>
<item>Thomas Esser and Olaf Weber (teTeX and Web2c, <emph>sine qua
	non</emph>)</item>
<item>Fabrice Popineau (Windows) and Gerben Wierda (MacOSX)</item>
<item>Staszek Wawrykiewicz, the conscience</item>
<item>Mimi Burbank, Kaja Christiansen, Karl Berry, Petr Olsak, and
       others (testers and compilers)</item>
<item>Hans Hagen, Martin Schröder, Norbert Preining, Vladimir Volovich
       and others (active contributors)</item>
<item>... and all the LUG teams which have produced and distributed it</item>
     </list>
    </p>
   </div>
<div rend="slide">
<head>Management</head>
<p>TeX Live sits in the Perforce change management system, which
looks after:
<list>
<item>File change history (date, comments, responsibility</item>
<item>Security (only named people can change things)</item>
<item>State (it knows who has which version of each file)</item>
<item>Conflict (it tracks who has edited what file)</item>
<item>Management of branches (main vs development source)</item>
     </list>
Just over 3000 changes (one change may involve many files)
have been committed to the TeX Live repository, by about 20 people.</p>
   </div>

<div rend="slide">
<head>Keeping it up to date</head>
<p>
<list type="ordered" rend="pausing">
<item>Updating source tree (mainly follows Olaf/Thomas, plus Martin
       for pdfTeX)</item>
<item>Recompiling for different systems (various)</item>
<item>Keeping Windows in sync and vice versa (Fabrice)</item>
<item>Updating macro and font packages from CTAN (mainly
       Sebastian)</item>
<item>Installation programs (Unix: mainly Sebastian, Windows:
       Fabrice)</item>
<item>Metadata and structural integrity (Sebastian and Fabrice)</item>
<item>Documentation (was Sebastian, now looking for an owner)</item>
<item>Testing (the TeXLive mailing list)</item>
<item>Production (LUGs and publishers)</item>
     </list>
    </p>
   </div>

<div rend="slide">
<head>Updating from CTAN</head>
<p>For a given package <Code>foo</Code>,
<list type="ordered">
<item>Pull a zip file from CTAN and unpack</item>
<item>Run a Perl script which makes a texmf free just for this
       package</item>
<item>Compare files in that texmf tree with the contents of
the metadata lists in the master, and add/delete/edit files in Perforce
       accordingly</item>
<item>Update metadata about <Code>foo</Code> and collections to which
it might belong</item>
     </list>
    </p>
   </div>

<div rend="slide">
<head>CTAN to TDS: the sausage machine</head>
<p>The Perl script has to
<list type="ordered">
<item>Work out the source directory structure</item>
<item>Run LaTeX .ins files if needed</item>
<item>Compile Metafont to TFM if needed</item>
<item>Move files to target directory based on file suffix</item>
     </list>
The main problem is interpreting file suffixes: is
     <Code>xxx.tex</Code>
a runtime macro file, documentation, or a test file?
The <Code>ctan2tds.pl</Code> script allows for exceptions
to be defined for each package.</p>

<p>Yes, this is extraordinarily flaky.</p>
   </div>

<div rend="slide">
<head>Default file Suffix rules</head>
<Screen><![CDATA[$standardins='\.ins';
$standardinsrunner="latex";
$standardtex='\.cfg|\.ist|\.sty|\.clo|\.ldf|\.cls|\.def|\.fd$';
$standarddvi='\.tex|\.ltx'; 
$standarddoc='liesmich|LIESMICH|LICENSE|License|Readme|READ.*|
 .*read.*|\.txt|\.gif|\.htm|\.TXT|\.pdf|\.doc|\.tex|\.dvi|\.html|
  \.gif|\.jpg|\.[0-9]$|\.[0-9][0-9]$|\.faq|\.bug';
$standardmp='\.mp';
$standardbst='\.bst';
$standardbib='\.bib';
$standardmf='[0-9]\.mf';
$standardpro='\.pro|\.enc';
$standardafm='\.afm';
$standardpfm='\.pfm';
$standardpfb='\.pfb';
$standardovf='\.ovf';
$standardofm='\.ofm';
$standardovp='\.ovp';
$standardotp='\.otp';
$standardocp='\.ocp';
$standardxmt='\.xmt';    ]]></Screen>
   </div>

<div rend="slide">
<head>An example override</head>
<Screen><![CDATA[%specialdoc= (
 'ae','README',
 'aguplus','readme.pwd|aguplus.tex|shorthnd.tex',
 'antyktor','\.inf',
 'barr','diagdoc.dvi|diagdoc.tex',
 'base','\.err|\.txt|.*info.tex|.*guide.*tex
    |.*news.*tex|\.dvi',
 'calxxxx','readme.tex',
 'chess','\.ltx|\.tex|\.dvi',
 'codepage','\.dvi',
 'clock','texclock.*|[A-Z]*',
 'custbib','\.dvi',
 'custom-bib','\.dvi',
 'cyrillic','\.txt',
 'emp','manual.ps',
 'feynmf','man\.*|Tutorial|Feynman\.Diagrams|\.dvi')]]></Screen>
   </div>

<div rend="slide">
<head>Overriding defaults</head>
<p>For zefonts package:
<Screen><![CDATA[sub MAKEzefonts {
 &setup;
 chdir("$DEST/source/latex/$package");
 system("mv texinput/* vf/* tfm/* doc/* dvips/* .; rm test.ps; rmdir texinput vf tfm dvips doc");
 &buildfilelist;
 &donormal;
}
     ]]></Screen>
and for ukrhyph:
<Screen><![CDATA[sub MAKEukrhyph {
# this simply copies source files
  chdir($packagedir) || die ("ERROR: cannot open directory");
  &runjob("mkdir -p $DEST/$texroot/generic/ukrhyph");
  &runjob("mkdir -p $DEST/doc/generic/ukrhyph");
  &runjob("cp README $DEST/doc/generic/ukrhyph");
  &runjob("cp *.* $DEST/$texroot/generic/ukrhyph");
  &runjob("mv $DEST/$texroot/generic/ukrhyph/*.pdf $DEST/doc/generic/ukrhyph");
  &runjob("rm $DEST/$texroot/generic/ukrhyph/*.ps");
 }]]></Screen>
    </p>
   </div>

<div rend="slide">
<head>How does installation work?</head>
<p>The TeX Live installers work at 5 levels:
<list type="gloss" rend="pausing">
<label>schemes</label>
<item>Specifications for a complete install (eg "texlive recommended"),
       which
references <emph>collections</emph> and <emph>packages</emph></item>
<label>collections</label>
<item>Specifications for a job (eg "Greek typesetting support")
       which can
reference other <emph>collections</emph>, but more often <emph>packages</emph></item>
<label>packages</label>
<item>Specifications for an authored package (eg "hyperref")
 which can reference other packages, but normally deals with
<emph>file groups</emph></item>
<label>file groups</label>
<item>Types of files to install ("runtime", "documentation" and "source")
</item>
<label>files</label>
<item>Lists of file names to be copied to the target installation</item>
     </list>
    </p>
   </div>
<div rend="slide">
<head>Where are these packages specified?</head>
<p>In XML files (.tpm, based on RDF. Each file
tells you all sorts of useful things:
<Screen><![CDATA[  <rdf:Description 
about="http://texlive.dante.de/texlive/package/koma-script.zip">
    <TPM:Name>koma-script</TPM:Name>
    <TPM:Type>package</TPM:Type>
    <TPM:Date>2003/03/28 15:54:00</TPM:Date>
    <TPM:Version>2.9l</TPM:Version>
    <TPM:Creator>rahtz</TPM:Creator>
    <TPM:Title>European typography for article/book/report classes.</TPM:Title>
    <TPM:Size>8969960</TPM:Size>
    <TPM:Description>
A drop-in replacement for the article/report/book 
classes with emphasis on European rules of typography 
and paper formats as laid down by Tschichold. 
The article class, for example, becomes scrartcl.
    </TPM:Description>]]></Screen>
</p>
   </div>

<div rend="slide">
<head>More TPM: filelists, dependencies and post-install</head>
<p><Screen><![CDATA[    <TPM:DocFiles size="1095427">
texmf/doc/fonts/pxfonts/README.texlive
texmf/doc/fonts/pxfonts/pxfontsdoc.pdf
texmf/doc/fonts/pxfonts/pxfontsdoc.tex
texmf/doc/fonts/pxfonts/pxfontsdocA4.pdf
texmf/doc/fonts/pxfonts/pxfontsdocA4.tex
    </TPM:DocFiles>
    <TPM:Requires>
      <TPM:Package name="txfonts"/>
    </TPM:Requires>
    <TPM:Installation>
      <TPM:Execute function="addMap" parameter="pxfonts.map"/>
    </TPM:Installation>
    <TPM:Provides>package/pxfonts</TPM:Provides>
]]></Screen></p>
   </div>

<div rend="slide">
<head>Collection TPM</head>
<p><Screen><![CDATA[    <TPM:Name>tex-chemistry</TPM:Name>
    <TPM:Type>collection</TPM:Type>
    <TPM:Date>2003/04/01 02:34:03</TPM:Date>
    <TPM:Version>1.0</TPM:Version>
    <TPM:Creator>rahtz</TPM:Creator>
    <TPM:Title>Chemical typesetting</TPM:Title>
    <TPM:Size>1133</TPM:Size>
    <TPM:Description>Essential chemistry</TPM:Description>
    <TPM:Build>
      <TPM:RunPatterns>texmf/tpm/collection/tex-chemistry.tpm</TPM:RunPatterns>
    </TPM:Build>
    <TPM:RunFiles size="1136">texmf/tpm/collection/tex-chemistry.tpm</TPM:RunFiles>
    <TPM:Requires>
      <TPM:Package name="bpchem"/>
      <TPM:Package name="chemarrow"/>
      <TPM:Package name="chemcono"/>
      <TPM:Package name="chemsym"/>
      <TPM:Package name="xymtex"/>
      <TPM:Collection name="tex-basic"/>
    </TPM:Requires>
]]></Screen></p>
<p>(see <xref url="cat.html">web dependency catalogue</xref>)</p>
   </div>

<div rend="slide">
<head>TPM: what next?</head>
<p>
<list type="ordered">
<item>Integrate with Graham William's Catalogue to provide
a single metadata system</item>
<item>Maintain XML files on CTAN as the definitive resource</item>
<item>Merge in pre-compilation information from TeX Live sausage
       machine</item>
<item>Provide web-based editing facilities for authors and packagers</item>
     </list>
From this (with luck):
<list>
<item>TeX Live, teTeX, MikTeX etc can use the information
for installation and (most importantly!) upgrade</item>
<item>CTAN can provide new views and searching facilities</item>
<item>The users can query their own installed systems</item>
     </list>
    </p>
   </div>

<div rend="slide">
<head>TeX Live 8: whats new?</head>
<p>
<list>
<item>web2c 7.4.5</item>
<item>pdfTeX 1.10b</item>
<item>Hundreds of updated macro packages</item>
<item>All the improvements in recent teTeX (eg updmap)</item>
<item>TeX Live has become too big. So delivery is in three formats:
<list type="ordered">
<item>Compressed (zip) archives on CD, with install programsm</item>
<item>Uncompressed system on DVD, like previous releases</item>
<item>Installed (subset) snapshot on CD, ready to run (no installer)</item>
       </list></item>
     </list>
    </p>
   </div>

<div rend="slide">
<head>Windows specific</head>
<p>The XEmTeX project has been funded by the French Ministry for
     Education for 18 months, started end of 2002. Several goals:
     <list>
      <item>Extend the set of TeX users</item>
      <item>Provide a free, integrated platform for typesetting
      scientific documents</item>
      <item>Based on the fact that TeX is more difficult to install and
      maintain than it is to use</item>
      <item>Documentation for new users</item>
     </list>
    </p>
   </div>
<div rend="slide">
<head>How to do it</head>
<p>Assemble available components :</p>
    <list>
     <item>TeX from TeXLive</item>
     <item>XEmacs + AUC-TeX + Preview-LaTeX (Thanks to David!)</item>
     <item>Ghostscript</item>
     <item>ImageMagick</item>
     <item>Perl</item>
    </list>
   </div>
<div rend="slide">
<head>Implications for TeXLive under Windows</head>
<p>
     <list>
     <item>No need to deal anymore with external programs (WinEdt&#8230;)</item>
     <item>Users will install either TeX or the XEmTeX bundle</item>
     <item>Using XEmTeX, users will:
       <list>
	<item>have access to the system using an icon</item>
	<item>use the provided support tools (Ghostscript,
	Imagemagick&#8230;) thanks to preconfiguration</item>
	<item>have access to new features on top of AUC-TeX to take
	advantage of the environment</item>
       </list>
      </item>
     </list>
    </p>
   </div>
  </body>
 </text>
</TEI.2>
