aboutsummaryrefslogtreecommitdiff
path: root/print/dvi2xx
diff options
context:
space:
mode:
authorJordan K. Hubbard <jkh@FreeBSD.org>1994-10-14 04:10:03 +0000
committerJordan K. Hubbard <jkh@FreeBSD.org>1994-10-14 04:10:03 +0000
commit595a0f47cd2fe1124dc14e5a48a1ca7880fc5502 (patch)
tree08b30e3f68b983859fec201902142100635650b1 /print/dvi2xx
parent5f026190c63626c1d89c2a742e9359d8598ca243 (diff)
downloadports-595a0f47cd2fe1124dc14e5a48a1ca7880fc5502.tar.gz
ports-595a0f47cd2fe1124dc14e5a48a1ca7880fc5502.zip
Notes
Diffstat (limited to 'print/dvi2xx')
-rw-r--r--print/dvi2xx/Makefile37
-rw-r--r--print/dvi2xx/files/patch-aa19
-rw-r--r--print/dvi2xx/pkg-comment1
-rw-r--r--print/dvi2xx/pkg-descr22
-rw-r--r--print/dvi2xx/pkg-plist18
-rw-r--r--print/dvi2xx/scripts/configure186
6 files changed, 283 insertions, 0 deletions
diff --git a/print/dvi2xx/Makefile b/print/dvi2xx/Makefile
new file mode 100644
index 000000000000..d5225cdb2f7b
--- /dev/null
+++ b/print/dvi2xx/Makefile
@@ -0,0 +1,37 @@
+DISTNAME= dvi2xx
+DISTFILES= dvi2xx.tar.gz
+
+#other equivalent sites: ftp.shsu.edu dtp.dante.de
+CTAN= ftp.tex.ac.uk
+FTP_DIR= /tex-archive/dviware
+FTPGET= ${WRKDIR}/ftpget
+
+pre-fetch:
+ @if [ ! -d ${DISTDIR} ]; then mkdir -p ${DISTDIR}; fi
+ @mkdir -p ${WRKDIR}
+ @${SCRIPTDIR}/ftpget magic ${WRKDIR}
+
+fetch: pre-fetch ${DISTFILES}
+
+dvi2xx.tar.gz:
+ @(cd ${DISTDIR}; if [ ! -f $@ ]; then \
+ echo ">> $@ doesn't seem to exist on this system."; \
+ echo ">> Attempting to fetch it from a master site."; \
+ ${FTPGET} ${CTAN} ${FTP_DIR} $@ $@ ;\
+ if [ ! -f $@ ]; then \
+ echo ">> Couldn't fetch it - please try to retrieve this";\
+ echo ">> port manually into ${DISTDIR} and try again."; \
+ exit 1; \
+ else \
+ echo ">> $@ Fetched!" ; \
+ fi; fi)
+
+pre-install:
+ @mkdir -p ${PREFIX}/bin
+ @mkdir -p ${PREFIX}/man/man1
+ @mkdir -p ${PREFIX}/lib/dvi2xx
+ @(cd ${WRKSRC}; install -m 755 -c MakeTeXPK ${PREFIX}/bin)
+ @(cd ${WRKSRC}; install -c -m 644 2up.sty graybox.sty lj3-filter \
+ printcap.sample sample2.tex testpage.tex ${PREFIX}/lib/dvi2xx/)
+
+.include <bsd.port.mk>
diff --git a/print/dvi2xx/files/patch-aa b/print/dvi2xx/files/patch-aa
new file mode 100644
index 000000000000..1b3585de8224
--- /dev/null
+++ b/print/dvi2xx/files/patch-aa
@@ -0,0 +1,19 @@
+*** dvi2xx.c.orig Mon Apr 25 06:50:00 1994
+--- dvi2xx.c Wed Oct 12 16:43:09 1994
+***************
+*** 606,612 ****
+ extern noshare int errno;
+ extern noshare char *sys_errlist[];
+ #else
+! extern char *sys_errlist[];
+ extern int errno;
+ #endif
+
+--- 606,612 ----
+ extern noshare int errno;
+ extern noshare char *sys_errlist[];
+ #else
+! /* extern char *sys_errlist[];*/
+ extern int errno;
+ #endif
+
diff --git a/print/dvi2xx/pkg-comment b/print/dvi2xx/pkg-comment
new file mode 100644
index 000000000000..544a6e589687
--- /dev/null
+++ b/print/dvi2xx/pkg-comment
@@ -0,0 +1 @@
+dvilj2, dvilj2p, dvilj, dviljp, dvi3812: convert dvi files to HP LaserJet or IBM 3812 format
diff --git a/print/dvi2xx/pkg-descr b/print/dvi2xx/pkg-descr
new file mode 100644
index 000000000000..610cec27dca2
--- /dev/null
+++ b/print/dvi2xx/pkg-descr
@@ -0,0 +1,22 @@
+Dvilj2 converts TeX-output .dvi files into HP PCL (i.e. HP Printer
+Control Language) commands suitable for printing on a HP LaserJet+, HP
+LaserJet II and fully compatible printers.
+
+Dvilj2p converts TeX-output .dvi files into HP PCL commands suitable
+for printing on a HP LaserJet IIp, HP LaserJet III or HP Laserjet 2000
+and fully compatible printers. This version uses a newer PCL command
+set and provides landscape printing.
+
+Dviljp and dvilj are similar to dvilj2p and dvilj2 but they support
+only 128 character fonts. They may be used for Laserjet clones which
+do not support 256 character fonts.
+
+Dvilj4 is for the HP LasterJet IV printer familiy and fully compatible
+clones. It implements a superset of the commands available for dvilj2p
+and prints with an resolution of 600 dpi. In addition it provides
+support for the printers builtin fonts using Karl Berry's coding
+scheme.
+
+Dvi3812 converts TeX-output .dvi files into PMP files, the native
+command language of the IBM 3812 page printer.
+
diff --git a/print/dvi2xx/pkg-plist b/print/dvi2xx/pkg-plist
new file mode 100644
index 000000000000..5b6745316c4c
--- /dev/null
+++ b/print/dvi2xx/pkg-plist
@@ -0,0 +1,18 @@
+@cd /usr/local
+@owner bin
+@mode 755
+bin/MakeTeXPK
+bin/dvi3812
+bin/dvilj
+bin/dvilj2
+bin/dvilj2p
+bin/dvilj4
+bin/dviljp
+@mode 644
+man/man1/dvi2xx.1
+lib/dvi2xx/2up.sty
+lib/dvi2xx/lj3-filter
+lib/dvi2xx/sample2.tex
+lib/dvi2xx/graybox.sty
+lib/dvi2xx/printcap.sample
+lib/dvi2xx/testpage.tex
diff --git a/print/dvi2xx/scripts/configure b/print/dvi2xx/scripts/configure
new file mode 100644
index 000000000000..1e667640720d
--- /dev/null
+++ b/print/dvi2xx/scripts/configure
@@ -0,0 +1,186 @@
+#!/bin/sh
+
+cd $WRKSRC || exit 1;
+
+mv lj3-filter lj3-filter.orig || exit 1;
+sed -e s:/usr/local/bin/perl:/usr/bin/perl: \
+ -e s:/usr/tmp/:/tmp/: \
+ -e s:/usr/local:$PREFIX: <lj3-filter.orig >lj3-filter
+
+mv config.h config.h.orig || exit 1;
+sed -e s+/usr/local/lib/tex/pk300+$PREFIX/lib/texmf/fonts/pk:/tmp/pk+ \
+ -e s+/usr/local/lib/tex/+$PREFIX/lib/texmf/+ < config.h.orig > config.h
+
+chmod +w Makefile || exit 1;
+echo "FONTAREA=" >> Makefile || exit 1;
+echo "DEFAULT_TFM_PATH=" >> Makefile
+echo "BINDIR=$PREFIX/bin" >> Makefile
+echo "MANDIR=$PREFIX/man" >> Makefile
+echo "CC=cc" >> Makefile
+
+mv MakeTeXPK MakeTeXPK.orig || exit 1;
+# MakeTeXPK taken from xdvi/dvips
+cat >>MakeTeXPK <<'EOF'
+#!/bin/sh
+#
+# This script file makes a new TeX PK font, because one wasn't
+# found. Parameters are:
+#
+# name dpi bdpi magnification [mode [subdir]]
+#
+# `name' is the name of the font, such as `cmr10'. `dpi' is
+# the resolution the font is needed at. `bdpi' is the base
+# resolution, useful for figuring out the mode to make the font
+# in. `magnification' is a string to pass to MF as the
+# magnification. `mode', if supplied, is the mode to use.
+#
+# Note that this file must execute Metafont, and then gftopk,
+# and place the result in the correct location for the PostScript
+# driver to find it subsequently. If this doesn't work, it will
+# be evident because MF will be invoked over and over again.
+#
+# Of course, it needs to be set up for your site.
+#
+TEXDIR=$PREFIX/lib/texmf
+LOCALDIR=/tmp
+DESTDIR=$LOCALDIR/pk
+#
+# TEMPDIR needs to be unique for each process because of the possibility
+# of simultaneous processes running this script.
+#
+if test "$TMPDIR" = ""
+then
+ TEMPDIR=/tmp/mtpk.$$
+else
+ TEMPDIR=$TMPDIR/mtpk.$$
+fi
+NAME=$1
+DPI=$2
+BDPI=$3
+MAG=$4
+MODE=$5
+#
+# Prevent display under the X Window System. Except it doesn't always work;
+# some sh'ells don't seem to understand unset. There are also some
+# versions of METAFONT that don't work if the DISPLAY isn't set and
+# the term type is set to xterm.
+#
+# unset DISPLAY
+umask 0
+
+if test "$MODE" = ""
+then
+ if test $BDPI = 300
+ then
+ MODE=imagen
+ elif test $BDPI = 200
+ then
+ MODE=FAX
+ elif test $BDPI = 360
+ then
+ MODE=nextII
+ elif test $BDPI = 400
+ then
+ MODE=nexthi
+ elif test $BDPI = 100
+ then
+ MODE=nextscreen
+ elif test $BDPI = 72
+ then
+ MODE=seventwo
+ elif test $BDPI = 635
+ then
+ MODE=linolo
+ elif test $BDPI = 1270
+ then
+ MODE=linohi
+ elif test $BDPI = 2540
+ then
+ MODE=linosuper
+ else
+ echo "I don't know the mode for $BDPI"
+ echo "Have your system admin update MakeTeXPK"
+ exit 1
+ fi
+fi
+
+# Something like the following is useful at some sites.
+# DESTDIR=/usr/local/lib/tex/fonts/pk.$MODE
+GFNAME=$NAME.$DPI'gf'
+PKNAME=$NAME.$DPI'pk'
+
+# Clean up on normal or abnormal exit
+trap "cd /; /bin/rm -rf $TEMPDIR $DESTDIR/pktmp.$$" 0 1 2 15
+
+
+if test ! -d $DESTDIR
+then
+ mkdir $DESTDIR
+ chmod 777 $DESTDIR
+fi
+
+if test "$6" != ""
+then
+ DESTDIR=$DESTDIR"$6"
+ if test ! -d $DESTDIR
+ then
+ mkdir $DESTDIR
+ chmod 777 $DESTDIR
+ fi
+fi
+
+# added by gwb, to allow searching in current dir before cd'ing
+if test "$MFINPUTS" != ""
+then
+ MFINPUTS=$MFINPUTS:`pwd`; export MFINPUTS
+fi
+mkdir $TEMPDIR
+cd $TEMPDIR
+
+if test -r $DESTDIR/$PKNAME
+then
+ echo "$DESTDIR/$PKNAME already exists!"
+ exit 0
+fi
+
+# check also in the standard place
+
+if test "$6" = ""
+then
+ if test -r $TEXDIR/fonts/pk/$PKNAME
+ then
+ echo $TEXDIR/fonts/pk/$PKNAME already exists!
+ exit 0
+ fi
+else
+ if test -r $TEXDIR/fonts/pk/$6"$PKNAME"
+ then
+ echo $TEXDIR/fonts/pk/$6"$PKNAME" already exists!
+ exit 0
+ fi
+fi
+
+unset DISPLAY
+echo "mf \"\\mode:=$MODE; mag:=$MAG; scrollmode; input $NAME\" < /dev/null"
+mf "\mode:=$MODE; mag:=$MAG; scrollmode; input $NAME" < /dev/null
+if test ! -r $GFNAME
+then
+ echo "Metafont failed for some reason on $GFNAME"
+ exit 1
+fi
+
+gftopk -v ./$GFNAME ./$PKNAME
+
+# Install the PK file carefully, since others may be doing the same
+# as us simultaneously.
+
+mv $PKNAME $DESTDIR/pktmp.$$
+cd $DESTDIR
+mv pktmp.$$ $PKNAME
+chmod a+r $PKNAME
+
+exit 0
+
+EOF
+chmod +x MakeTeXPK
+exit 0;