diff options
author | Karl Berry <karl@freefriends.org> | 2006-01-17 21:41:51 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2006-01-17 21:41:51 +0000 |
commit | 487ca4806cc046076293cf6cc5fbba0db282bac7 (patch) | |
tree | 847b412ab5158dd7bdd7ed7e5a4cc3fbca94be32 /Build/source/texk/dtl/man2ps | |
parent | a3d3111bfe26b8e5f5bc6049dfb2a4ca2edc7881 (diff) |
texk 1
git-svn-id: svn://tug.org/texlive/trunk@1485 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/dtl/man2ps')
-rw-r--r-- | Build/source/texk/dtl/man2ps | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/Build/source/texk/dtl/man2ps b/Build/source/texk/dtl/man2ps new file mode 100644 index 00000000000..8d0f2304438 --- /dev/null +++ b/Build/source/texk/dtl/man2ps @@ -0,0 +1,36 @@ +#!/bin/sh +# Filter for converting "troff -mxx" to PostScript. This script is +# normally linked to the names man2ps, ms2ps, me2ps, and mm2ps. +# +# Usage: +# man2ps [<] cc.1 >cc.ps +# me2ps [<] foo.me >foo.ps +# mm2ps [<] foo.mm >foo.ps +# ms2ps [<] foo.ms >foo.ps +# +# [08-May-1993] + +# Choose a troff format according to the scrip name. +case `basename $0` in + man*) FORMAT=-man ;; + me*) FORMAT=-me ;; + mm*) FORMAT=-mm ;; + ms*) FORMAT=-ms ;; + *) echo "Unknown troff format:" ; exit 1 ;; +esac + +# We can use either GNU groff or Sun Solaris troff + dpost +if [ -x /usr/local/bin/groff ] +then # GNU groff + TROFF="groff $FORMAT" + TROFF2PS="cat" +elif [ -x /usr/lib/lp/postscript/dpost ] +then # Solaris 2.1 + TROFF="troff $FORMAT" + TROFF2PS="/usr/lib/lp/postscript/dpost" +else + echo "Cannot find troff-to-PostScript filter" + exit 1 +fi + +tbl $* | eqn | $TROFF | $TROFF2PS |