OpenBSD installation
this page contains instructions how to get the latest ConTeXt up and running on OpenBSD 3.8+
Contents
install gmake
# pkg_add gmake
install teTeX 3.0
# pkg_add teTex_base-3.0p3
this adds all the dependencies with newer pkg tools. if using older ones, add the other packages manually (teTeX_texmf, teTeX_base-fmt).
strictly speaking, one doesn't need X11 for using teTeX, in this case install the *-no_x11 packages.
update pdftex
get the latest version from sarovar.
# tar xvzf pdftex-1.30.6.tgz
# cd pdftex-1.30.6
apply the following diff (scratch the bashism and use gmake):
--- build.sh.orig Mon Feb 27 21:45:29 2006
+++ build.sh Mon Feb 27 23:32:31 2006
@@ -1,7 +1,7 @@
-#! /usr/bin/env bash
+#!/bin/sh
# $Id$
# builds new pdftex binaries
-MAKE=make
+MAKE=gmake
STRIP=strip
# this deletes all previous builds.
run the build:
# sh ./build.sh
when finished, replace the binaries (pdftex is only a symlink to pdfetex):
# cp build/texk/web2c/pdfetex which pdfetex
# cp build/texk/web2c/pdfetex.pool kpsewhich pdfetex.pool
# cp build/texk/web2c/ttf2afm which ttf2afm
# fmtutil-sys --all
the last command will update all the formats except the ones which come with context. please note that this will also break the md5 package checksums of the teTeX packages and will leave partial packages when they are being removed/upgraded.
update mpost
this is optional. fetch the source from here
# bunzip2 metapost-0.901.tar.bz2
# tar xvf metapost-0.901.tar
# cd metapost-0.901
apply a very similar diff as with pdftex (scratch the bashism and use gmake):
--- Build.orig Sat Mar 4 18:34:06 2006
+++ Build Sat Mar 4 18:34:15 2006
@@ -1,7 +1,7 @@
-#!/usr/bin/env bash
+#!/bin/sh
# $Id: Build,v 1.3 2005/05/08 15:55:26 taco Exp $
# builds new pdftex binaries
-MAKE=make
+MAKE=gmake
STRIP=strip
# this deletes all previous builds.
run the build:
# ./Build
# mkdir -p /usr/local/share/texmf-local/metapost/base
# cp -p texmf/metapost/base/* \
/usr/local/share/texmf-local/metapost/base
# cd build/texk/web2c
# mv mpost dvitomp mpware/dmp mpware/mpto mpware/newer mpware/makempx \
/usr/local/bin
# mv mp.pool /usr/local/share/texmf/web2c/mp.pool
# texhash
# fmtutil-sys --byfmt mpost
modify texmf.cnf
apply the following diff to /usr/local/share/texmf/web2c/texmf.cnf
--- texmf.cnf.orig Tue Mar 7 00:01:07 2006
+++ texmf.cnf Tue Mar 7 00:02:16 2006
@@ -246,7 +246,7 @@
% and string pools (.pool) for ini{tex,mf,mp}. It is silly that we have six
% paths and directories here (they all resolve to a single place by default),
% but historically ...
-TEXFORMATS = .;$TEXMF/web2c
+TEXFORMATS = .;$TEXMF/web2c{$engine,}
MFBASES = .;$TEXMF/web2c
MPMEMS = .;$TEXMF/web2c
TEXPOOL = .;$TEXMF/web2c
@@ -409,7 +409,7 @@
TEX_HUSH = none
% Enable system commands via \write18{...}?
-shell_escape = f
+shell_escape = t
% Allow TeX \openin, \openout, or \input on filenames starting with `.'
% (e.g., .rhosts) or outside the current tree (e.g., /etc/passwd)?
more about these changes here and here.
warning: shell_escape = t is a security issue when you're on a system with many users; if you're running it on your own personal computer, it is safe to set this to true. (Thomas A. Schmitz)
upgrade Latin Modern fonts
download and install the lm fonts. delete the old files preferably, many filenames were changed since the teTeX 3.0 times. when finished run:
$ sudo texhash
upgrade ConTeXt
get the latest package from here.
$ cd /usr/local/share/texmf-local/
$ sudo unzip -o $HOME/cont-tmf.zip
$ sudo texexec --make --all
the formats will end up in $HOME/.texmf-var/web2c/pdfetex/ of the user doing the compiling. to make them globally accessible, one needs to copy/move them to the system-wide location:
$ sudo mv $HOME/.texmf-var/web2c/pdfetex /var/texmf/web2c/
$ sudo texhash