Install VTeX

Last week I got a job to compile a LaTeX document, presumably composed for VTeX, an ancient TeX distribution. For that I had to install VTeX first, but resource on that was surprisingly sparse. So I decided to document how I did that.

The difficulties mainly came from the fact that VTeX is ancient - the last update being in 2005, when most computers were using 32-bit processors. Although VTeX only depends on glibc, it is time-consuming to find and install those outdated libraries on a modern Linux distribution. After some trials and errors, I decided to do the brute-force and install Ubuntu 4.10 (the oldest Ubuntu release that is listed on old-releases.ubuntu.com) in a virtual machine. So here comes the first trick. Since Ubuntu 4.10 is too old to include drivers for any modern hardware, it only supports CD drives attached to the IDE bus. As a result, the CD image must be attached as an IDE (instead of SATA, etc.) device, or the OS installer will complain.

The next step is somewhat straightforward. Go to micropress-inc.com and download the latest VTeX/Free release for Linux, which are basically 11 zip archives. Then follow the readme and unzip those files one by one to /usr/local/vtex. Add /usr/local/vtex/bin to $PATH. Also, /usr/local/vtex/install/vtex.ini needs to be moved to /etc.

Try following the readme and run makevlatex, and you should see some missing libraries begin reported by vtexlnx. Running ldd against /usr/local/vtex/bin/vtexlnx tells us that we need to get libstdc++-libc6.2-2.so.3. Here I decided to do the brute-force again. Some googling shows that libstdc++-libc6.2-2.so.3 is provided in this package, so I downloaded the deb and ran dpkg-deb -R to extract its contents. VTeX runs without issue now.

Note that, one can actually install 32-bit binary support, and put libstdc++-libc6.2-2.so.3 under the $LD_LIBRARY_PATH on any modern Linux distribution. ld will recognize this library and dynamically link vtexlnx to it. However, VTeX is so old that it depends on an old kernel, and it will complain if it is not running on such. Although The readme says that setting LD_ASSUME_KERNEL=2.4.1 may help resolve the issue, in my test it only made all my other applications to fail to link to libc and caused me headache. As a result, the only recommended way to install VTeX is installing it on a really-old Linux release.

As an optional final step, if you need SSH access, notice that the SSH key exchange algorithm in Ubuntu 4.10 is too outdated (and insecure) to many any modern SSH client happy. To overcome that, add KexAlgorithms +diffie-hellman-group1-sha1 to the corresponding host in your local SSH config file, so that the SSH client will break the rule for your VTeX VM.