The generic, teTeX distribution isn't any harder to install than the Linux packages. See section Generic CTAN distribution, below.
You should consider installing the generic teTeX distribution from the CTAN archives if:
A complete installation of the binary distribution requires 40-50 Mb of disk space, and building the distribution from the source code takes about 75 Mb, so you should make sure that the disk space is available before you start. You don't need to have the GCC compiler or the X Windows System installed (although X certainly helps because it is much easier to preview documents on-screen). All you need is an editor that is capable of producing plain ASCII, text (see section 2). What could be simpler?
You can retrieve the files from one of the CTAN archives listed in section Appendix A. In the examples below, the files were retrieved from the CTAN archive at ftp.tex.ac.uk.
First, FTP to
cd to the directory
ctan/tex-archive/systems/unix/teTeX/distrib/Retrieve the files
INSTALL.bin install.shand place them in the top-level directory where you want to install teTeX, for example,
/var/teTeXif you plan to install teTeX in the
Print out the
INSTALL.bin file. Keep this file handy,
because it describes how to install a minimal teTeX installation. The
minimal installation requires only 10-15 MB of disk space, but it is
recommended that you install the complete teTeX package if at all
possible. For a minimum installation, you'll need the files
ctan/tex-archive/systems/unix/teTeX/distrib/base/latex-base.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/base/tetex-base.tar.gzYou'll also need one of two archives which contain the executable teTeX programs. Retrieve the archive file
ctan/tex-archive/systems/unix/teTeX/distrib/binaries/i386-linux.tar.gzif your system uses the Linux ELF shared libraries,
ld.soof at least version 1.73, and clibs of at least version 5.09. If it doesn't, retrieve the archive
ctan/tex-archive/systems/unix/teTeX/distrib/binaries/i386-linuxaout.tar.gzwhich is compiled for systems that use the older, a.out-format static libraries.
Then, following the instructions in the file
execute the command
sh ./install.shwhile in the top-level teTeX installation directory. (Make sure that the teTeX archives are located there, too.) After a few moments, the installation program will warn you that you are missing some of the teTeX packages. However, if you're planning only a minimal teTeX installation, you should ignore the warnings and proceed. To configure the basic teTeX system, see section Base system configuration, below.
To install the remaining packages, see the next section.
To perform a complete teTeX installation, retrieve the archive files listed in the previous section, as well as the following files:
ctan/tex-archive/systems/unix/teTeX/distrib/doc/ams-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/bibtex-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/eplain-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/fonts-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/general-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/generic-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/latex-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/makeindex-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/metapost-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/doc/programs-doc.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/fonts/ams-fonts.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/fonts/dc-fonts.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/fonts/ec-fonts.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/fonts/misc-fonts.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/fonts/postscript-fonts.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/fonts/sauter-fonts.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/amstex.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/bibtex.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/eplain.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/latex-extra.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/metapost.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/pictex.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/pstricks.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/texdraw.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/goodies/xypic.tar.gzAll of these files should be placed in the top-level directory where you want teTeX to reside. As with the minimal installation, execute the command
install.sh script, after determining which teTeX archive
series are present, will present you with a menu of options. The only
setting you need to make at this point is to set the top-level
directory where you want teTeX installed, by selecting the ``D'' option.
You must, of course, choose a directory in whose parent directory you
have write permissions. For example, if you are installing teTeX in
your home directory, you would specify the teTeX installation
/home/john.q.public/teTeXand, after returning to the main menu, select ``I'' to proceed with the installation. Note that the directory must not exist already: the
install.shscript must be able to create it.
An option which you should consider enabling, is setting an alternative directory for generated fonts. Even if you plan to use only Postscript-format, Type 1 scalable fonts, occasionally you'll process a file that requires the Computer Modern fonts. Enabling this option requires that you enter the directory to use. You must have write permissions for the parent directory. Following the example above, you could specify
/home/john.q.public/texfontsor, if you want the generated fonts to be accessible by all users on the system, specify a directory like
/var/texfontsI would recommend that you not, however, use the default
/var/tmp/texfontsdirectory for this option, because the generated fonts could be deleted after the next reboot, and the fonts will need to be generated again the next time they're needed.
After you've selected the option ``I'', and
installed the archives, set various permissions, and generated its
links and format files, the program will exit with a message telling
you to add the teTeX binary directory to your
environment variable, and the directories where the man pages and info
files reside to your
$INFOPATH environment variables. For example, add the
export PATH=$PATH:"/home/john.q.public/teTeX/bin" export MANPATH=$MANPATH":/home/john.q.public/teTeX/man" export INFOPATH$=INFOPATH":/home/john.q.public/teTeX/info"to your
~/.bash_profileif you use
bashas your shell, or to your
~/.profileif you use another shell for logins.
Log out, and then log in again, so the environment variables are registered. Then, run the command
texconfig confallto insure that the installation is correct.
Next, you can configure teTeX for you specific hardware. See section Post-installation configuration details, below.
To install teTeX V. 0.4 from the source code,
ftp to a CTAN
ftp://ftp.tex.ac.uk and retrieve the files
ctan/tex-archive/systems/unix/teTeX/distrib/INSTALL.src ctan/tex-archive/systems/unix/teTeX/distrib/sources/README.texmf-src ctan/tex-archive/systems/unix/teTeX/distrib/sources/teTeX-lib-0.4pl8.tar.gz ctan/tex-archive/systems/unix/teTeX/distrib/sources/teTeX-src-0.4pl7.tar.gz
Read over the instructions in
to root and unpack the files in a directory for which you have
Remember to use the
p argument to
tar, and also
remember to unset the
noclobber option of
You can do this with the counterintuitive command
set +o noclobberNote that the argument
setunsets a variable, just exactly backwards from what you might expect.
teTeX-lib-0.4pl8.tar.gz will create the directory
./teTeX. The file
create the directory
teTeX-src-0.4 Print out the file
INSTALL.src and keep it nearby for the following
cd to the
./teTeX-src-0.4 directory, and, per
the instructions in the
INSTALL.src file, edit
./Makefile. You need to set the
to the absolute path of the parent teTeX directory. This will be the
teTeX of the directory where you unpacked the
source and library archives. For example, if you unpacked the
archives in your home directory, you would set
/home/john.q.public/teTeXThe rest of the
Makefileoptions are pretty generic. With GCC version 2.7.2 and later, you should not need to make any further adjustments unless you have a non-standard compiler and library setup, or want the compiler to perform some further optimizations, or for some other reason. Check that the
HAVE_NCURSESvariables are set correctly for your system, because the
dialogprogram needs the ncurses library to be installed. A
ncurseslibrary is included in the source distribution, so the default values in the
Makefileshould work fine. If you can't get
ncursesto compile or link,
texconfigcan also be run from the command line.
If you've done everything correctly up to this point, you should be
able to type
make world in the top-level source directory,
and relax until the teTeX executables are built. This can take a few
After the build has completed, set the environment variables
$PATH, $MANPATH, and
to include the teTeX directories. The statements which would be added
to the file
~/.bash_profile, in the example, above,
export PATH=$PATH":/home/john.q.public/teTeX/bin/i386-linux" export MANPATH=$MANPATH":/home/john.q.public/teTeX/man" export INFOPATH=$INFOPATH":/home/john.q.public/teTeX/info"The
$PATHvariable is different in the source distribution than in the binary distribution. Note that here the path to the binaries is
teTeX/bin/i386-linuxinstead of simply
teTeX/binas in the binary distribution.
At this point you can run
texconfig confall to ensure that
the paths have been set correctly, and then proceed to configure teTeX
as in the binary distribution. See the
Post-installation configuration details, below.
The first thing you want to do is look at Thomas Esser's
README file. It contains a lot of hints on how to configure
teTeX for your output device (i.e., printer). The
file is located in the directory
/usr/lib/teTeX/texmf/doc/tetexRead the file over with the command (the path in the following examples is that of the Slackware distribution):
less /usr/lib/teTeX/texmf/doc/tetex/READMEor, print it out with the command
cat /usr/lib/teTeX/texmf/doc/tetex/README >/dev/lp0assuming that your printer is connected to
/dev/lp0. Substitute the device driver file that your printer is connected to, as appropriate.
Or, better still, print it using the
lpr /usr/lib/teTeX/texmf/doc/tetex/READMEYou should have installed the printer daemon that is included with your distribution of Linux. If not, do that now, per the instructions that come with the package.
Print out the
teTeX-FAQ. Keep the FAQ handy because it
contains useful hints for configuring teTeX's output drivers for your
printer. We'll get to that in a moment. In more recent releases of
teTeX-FAQ is viewable via the
Next, you want to define a directory to store your own TeX
format files. teTeX searches the directories listed by the
$TEXINPUTS environment variable for local TeX input
export TEXINPUTS=".:~/texinputs:"to the system-wide
/etc/profilefile. Individual users can set their own local
$TEXINPUTSdirectory, by adding the line in their
bashis the default shell. The
$TEXINPUTSenvironment variable tells teTeX to look for users' individual TeX style files in the
~/texinputsdirectories under each user's home directory. It is critical that a colon appear before and after this directory. teTeX is going to append its own directory searches to your own. You want to have teTeX search the local format files first, so it uses the local versions of any of the standard files you have edited.
/usr/lib/teTeX/bin directory to the system-wide path
if you're installing teTeX as root. Again, if you're installing a
personal copy of teTeX, add the directory where the teTeX binaries are
located to the front your
$PATH with the
following line in your
export PATH="~/tetex/bin:"$PATHNow, log in as
texconfigper the instructions in the
teTeX-FAQand choose the printer that is attached to your system. Make sure that you configure teTeX for both the correct printer and printer resolution.
Finally, run the
texhash program. This ensures that teTeX's
internal database is up to date. The database is actually a
ls-lR file. You must run
time you change the system configuration, or teTeX will not be able to
locate your changes.