TexLive 2008 on FreeBSD

First download the ISO image, and compare the checksums (both md and sha based on avail); alternatively, buy the sucker on DVD :-).

Since I can’t afford a yearly DVD, and don’t have a spare disk; I need to unpack the ISO and mount it directly. If you bought the disk, mount it as normal. For me, this procedure required:

dixie# lzma d texlive2008-20080822.iso.lzma texlive2008-20080822.iso.lzma


LZMA 4.60 beta Copyright (c) 1999-2008 Igor Pavlov 2008-08-19

dixie# mdconfig -a -v -t vnode -u 10 -f texlive2008-20080822.iso


dixie# mount -t cd9660 /dev/md10 /mnt


dixie# ls /mnt


.mkisofsrc index.html source

LICENSE.CTAN install-tl support

LICENSE.TL install-tl.bat texmf

README install-tl.bat.manifest texmf-dist

README.usergroups readme-html.dir texmf-doc

autorun.inf readme-txt.dir tl-portable

bin release-texlive.txt tl-portable.bat

doc.html rr_moved tlpkg

Now that the ISO is ready op, we can start the installation. TexLive uses a nice Perl based installer, if you’ve got the necessary TK GUI modules for Perl installed, you can use a a -gui switch; me, I’m fine with the perl script.

Obviously, you will need lang/perl5 installed, along with the necessary dependencies for programs shipped in TeXLive. I don’t know what release of FreeBSD i386, the binaries in TexLive 2007 were compiled against, but 2008 used FreeBSD 7:

Terry@dixie$ file /usr/local/texlive/2007/bin/i386-freebsd/pdftex          0:11
/usr/local/texlive/2007/bin/i386-freebsd/pdftex: ELF 32-bit LSB executable, Intel 80386,
version 1 (FreeBSD), dynamically linked (uses shared libs), stripped
Terry@dixie$ file /usr/local/texlive/2008/bin/i386-freebsd/pdftex 0:13
/usr/local/texlive/2008/bin/i386-freebsd/pdftex: ELF 32-bit LSB executable, Intel 80386,
version 1 (FreeBSD), for FreeBSD 7.0 (700055), dynamically linked (uses shared libs),
FreeBSD-style, stripped
Terry@dixie$ 0:13

Several of the programs used in TexLive are sh/cmd wrappers, but once installed, you can get a general idea of dependencies with the following command:

Terry@dixie$ ldd /usr/local/texlive/2008/bin/i386-freebsd/* 2>- | pgr      0:17

N.B. 2>- means to close the standard error stream, what you need to type, may vary depending on shell; 2>- works on Bourne style shells (ash/dash, bash, ksh, zsh). In the case of shell script wrappers, you’ll need to open them, and manually parse to find anything hidden; most people don’t need to do this.

For the most part, the depends are on the systems C and C++ libraries (libc, libm, libstdc++), a few require other things, such as ncurses, zlib, the new libthr, and gcc related stuff – all this comes with FreeBSD 7. Some programs require X-related libraries (such as MetaFont), fontconfig, and freetype. If you have a working install of X.Org 7.3, you will probably be fine, while disk space holds out lol. The need for handling #!/bin/sh and ‘#!/usr/bin/env perl’ are of course a prerequisite. On my X based system, everything is ready. Checking all this out, shouldn’t be necessary, and any “missing” perl modules or libraries can be installed later: when required.

Anyway, let’s get to actually installing this sucker:

dixie# cd /mnt; ./install-tl


Platform: i386-freebsd => 'Intel x86 with FreeBSD'

Distribution: live (uncompressed)

Directory for temporary files: '/tmp'

Installer directory: '.'

Loading /mnt/tlpkg/texlive.tlpdb

======================> TeX Live installation procedure <=====================



=======> Note: Letters/digits in indicate menu items <=======

=======> for commands or configurable options <=======



Detected platform: Intel x86 with FreeBSD



<B> binary systems: 1 out of 15



<S> Installation scheme (scheme-full)

83 collections out of 84, disk space required: 1720 MB



Customizing installation scheme:

<C> standard collections

<L> language collections



<D> directories:

TEXDIR (the main TeX directory):

/usr/local/texlive/2008

TEXMFLOCAL (directory for site-wide local files):

/usr/local/texlive/texmf-local

TEXMFSYSVAR (directory for variable and automatically generated data):

/usr/local/texlive/2008/texmf-var

TEXMFSYSCONFIG (directory for local config):

/usr/local/texlive/2008/texmf-config

TEXMFHOME (directory for user-specific files):

~/texmf



<O> options:

[ ] use letter size instead of A4 by default

[X] create all format files

[X] install macro/font doc tree

[X] install macro/font source tree

[ ] create symlinks in standard directories



<V> set up for running from DVD



Other actions:

<I> start installation to hard disk

<H> help

<Q> quit



Enter command: i


Installing: [name of package]
.... repeated for each one, have fun waiting on z
running post install action for bin-texdoc

running post install action for bin-texlive

running post install action for texlive-cz

running post install action for texlive-de

running post install action for texlive-en

running post install action for texlive-fr

running post install action for texlive-pl

running post install action for texlive-ru

running post install action for texlive-zh-cn

running post install action for texlive.infra

running post install action for xetex

running mktexlsr /usr/local/texlive/2008/texmf-dist /usr/local/texlive/2008/texmf

mktexlsr: Updating /usr/local/texlive/2008/texmf-dist/ls-R...

mktexlsr: Updating /usr/local/texlive/2008/texmf/ls-R...

mktexlsr: Done.

writing fmtutil.cnf data to /usr/local/texlive/2008/texmf-var/web2c/fmtutil.cnf

writing updmap.cfg to /usr/local/texlive/2008/texmf-var/web2c/updmap.cfg

writing language.dat data to /usr/local/texlive/2008/texmf-var/tex/generic/config/language.dat

writing language.def data to /usr/local/texlive/2008/texmf-var/tex/generic/config/language.def

running mktexlsr /usr/local/texlive/2008/texmf-var

mktexlsr: Updating /usr/local/texlive/2008/texmf-var/ls-R...

mktexlsr: Done.

running updmap-sys... done

re-running mktexlsr /usr/local/texlive/2008/texmf-var

mktexlsr: Updating /usr/local/texlive/2008/texmf-var/ls-R...

mktexlsr: Done.

pre-generating all format files (fmtutil-sys --all), be patient...done



See

/usr/local/texlive/2008/index.html

for links to documentation. The TeX Live web site (http://tug.org/texlive/)

contains any updates and corrections.



TeX Live is a joint project of the TeX user groups around the world;

please consider supporting it by joining the group best for you. The

list of groups is available on the web at http://tug.org/usergroups.html.



Add /usr/local/texlive/2008/texmf/doc/man to MANPATH.

Add /usr/local/texlive/2008/texmf/doc/info to INFOPATH.

Most importantly, add /usr/local/texlive/2008/bin/i386-freebsd

to your PATH for current and future sessions.



Welcome to TeX Live!



./install-tl: done.

Logfile: /usr/local/texlive/2008/install-tl.log

After that completes, be it 10 minutes later or 10 hours, depending on your hardware…. If desired, one can customize the installation process. If the command prompt scares you, use install-tl -gui instead. You probably will want to setup your installation afterwords, the tlmgr program will be of use, and supports a -gui option I think. For me, all I do is set the default paper type, and update my environment so I can use TeXLive binaries, manuals, and info pages.

dixie# setenv PATH "/usr/local/texlive/2008/bin/i386-freebsd/:$PATH"
dixie# /usr/local/texlive/2008/bin/i386-freebsd/tlmgr paper a4


N.B. the default shell for root on FreeBSD is (t)csh. My interactive shells always sources ~/.site_shrc at the end of it’s setup, so this is where I set my environment, others would probably want ~/.bashrc or other shell specific file:

# TeX Live stuff
PATH="/usr/local/texlive/2008/bin/i386-freebsd:$PATH:/usr/games:/usr/local/bin:/usr/local/sbin:${HOME}/sh:${HOME}/bin"; export PATH
MANPATH="/usr/local/texlive/2008/texmf/doc/man:/usr/share/man:/usr/local/man:$MANPATH"; export MANPATH
INFOPATH="/usr/local/texlive/2008/texmf/doc/info:/usr/share/info:/usr/local/info:$INFOPATH"; export INFOPATH

and resource the file. As root, one can also add the manuals from TexLive to /etc/manpath.conf (read the comments in it), which will update the man commands search path, Updates to the environment can also be done to the various files in your skel system if desired, and mail existing users about the update. I’m not aware if there is a file to configure the info commands search path, probably is, but I don’t use info pages that often ^_^. I require each user account to adjust their own environment before using TexLive, which suits me fine. Once TexLive 2008 is ready op, and one is satisfied, /usr/local/texlive/2007 can be rm -rf’d, recovering around 1.1GB, depending on what you had installed. Also, my 2008 install is ~1.7GB. I generally opt-in to the defaults, but I expect many people would want to setup a more localized-only set of files. Now to clean up:

dixie# umount /mnt
dixie# mdconfig -d -u 10

Happy trails