home *** CD-ROM | disk | FTP | other *** search
Makefile | 1989-08-23 | 4.3 KB | 130 lines |
- #
- # Wright State University Remote LaserWriter Kit
- # John Sloan <jsloan%SPOTS.Wright.EDU@@Relay.CS.NET>
- # $Revision: 1.3 $
- # $Date: 89/08/06 02:27:15 $
- #
- # Modified by Dinah Anderson <dinah@bcm.tmc.edu>
- # Baylor College of Medicine
- # 89/8/23
- #
-
- # C Compiler flags (if any)
- CFLAGS=-DBRIDGE
-
- # Printcap name of remote LaserWriter
- PRINTER=motc
-
- # Local LaserWriter spool directory (must differ from NEWSPOOLDIR)
- PSSPOOLDIR=/usr/spool/lpd/local
-
- # New remote LaserWriter spool directory (must differ from PSSPOOLDIR)
- NEWSPOOLDIR=/usr/spool/lpd/motc
-
- # Original Transcript software directory (must differ from NEWLIBDIR)
- PSLIBDIR=/usr/local/lib/ps
-
- # New remote Transcript filters directory (must differ from PSLIBDIR)
- NEWLIBDIR=/usr/motc
-
- # Network name of host computer handling spooling to communication server
- # This is the computer on which you are installing this software
- HOST="`hostname`"
-
- # Network name of host communications server
- SERVER=128.249.4.40
-
- # Port number for LaserWriter on host
- PORT=23
-
- # Master pseudo-terminal (typically /dev/ptyXX, where XX=[pqrs][0-f])
- # You may roll your own (as we do) with /etc/mknod
- # Owner should be daemon and mode should be 666
- # Device should not appear in /etc/ttys as login enabled (with getty)
- PTY=/dev/ptyr4
-
- # Slave pseudo-terminal (typically /dev/ttyXX)
- # You may roll your own (as we do) with /etc/mknod
- # Owner should be daemon and mode should be 666
- # Device should not appear in /etc/ttys as login enabled (with getty)
- TTY=/dev/ttyr4
-
- # Location of servercomm(8l) man page
- MANDIR=/usr/man/manl
-
- #########################################################################
-
- all: servercomm filters printcap printcap.remote
-
- install: all ${NEWLIBDIR}/servercomm ${MANDIR} servercomm.8l
- cp /dev/null ${NEWLIBDIR}/${PRINTER}
- cp servercomm.8l ${MANDIR}
- chmod 644 ${MANDIR}/servercomm.8l
-
- clean:
- rm -if diffs printcap printcap.remote
-
- backout: clean
- rm -rif ${NEWSPOOLDIR} ${NEWLIBDIR}
-
- servercomm: servercomm.c
- cc ${CFLAGS} -O -o servercomm servercomm.c
-
- ${NEWLIBDIR}/servercomm: servercomm
- strip servercomm
- mv servercomm ${NEWLIBDIR}
- chmod 755 ${NEWLIBDIR}/servercomm
-
- test: debug hello.ps
- debug -v -x -h ${SERVER} -p ${PORT} -t ${PTY} ${TTY} -f ${NEWLIBDIR}/pscomm -P ${PRINTER} -p psif /dev/tty < hello.ps
- #debug -v -x -h ${SERVER} -p ${PORT} -t ${PTY} ${TTY} -f ${PSLIBDIR}/pscomm -P ${PRINTER} -p psif /dev/tty < hello.ps
-
- debug: servercomm.c
- cc ${CFLAGS} -g -DDEBUG -DDUMP -o debug servercomm.c
-
- filters: ${NEWLIBDIR} ${NEWLIBDIR}/psint.sh
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/psof
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/psif
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/psgf
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/psnf
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/pstf
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/psrf
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/psvf
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/pscf
- ln ${NEWLIBDIR}/psint.sh ${NEWLIBDIR}/psdf
-
- ${NEWLIBDIR}/psint.sh: ${PSLIBDIR}/psint.sh ${NEWLIBDIR} diffs
- cp ${PSLIBDIR}/psint.sh ${NEWLIBDIR}
- chmod 755 ${NEWLIBDIR}/psint.sh
- patch ${NEWLIBDIR}/psint.sh diffs
-
- ${NEWLIBDIR}:
- mkdir ${NEWLIBDIR}
- chmod 755 ${NEWLIBDIR}
-
- diffs:
- echo "67c67,68" > diffs
- echo "< comm=\"\$$PSCOMM -P \$$pname -p \$$prog -n \$$user -h \$$host \$$afile\"" >> diffs
- echo "---" >> diffs
- echo "> filter=\"\$$PSCOMM -P \$$pname -p \$$prog -n \$$user -h \$$host \$$afile\"" >> diffs
- echo "> comm=\"servercomm -h ${SERVER} -p ${PORT} -t ${PTY} ${TTY} -f \$$filter\"" >> diffs
-
- printcap:
- echo "${PRINTER}|LaserWriter on communication server ${SERVER} Port ${PORT}:\\" > printcap
- echo " :lp=${NEWLIBDIR}/${PRINTER}:sd=${NEWSPOOLDIR}:\\" >> printcap
- echo " :lf=${NEWSPOOLDIR}/lw-log:af=/usr/adm/lw.acct:\\" >> printcap
- echo " :mx#0:sf:sb:\\" >> printcap
- echo " :if=${NEWLIBDIR}/psif:\\" >> printcap
- echo " :of=${NEWLIBDIR}/psof:gf=${NEWLIBDIR}/psgf:\\" >> printcap
- echo " :nf=${NEWLIBDIR}/psnf:tf=${NEWLIBDIR}/pstf:\\" >> printcap
- echo " :rf=${NEWLIBDIR}/psrf:vf=${NEWLIBDIR}/psvf:\\" >> printcap
- echo " :cf=${NEWLIBDIR}/pscf:df=${NEWLIBDIR}/psdf:" >> printcap
-
-
- printcap.remote:
- echo "${PRINTER}|Remote LaserWriter on Host ${HOST} communication server ${SERVER} Port ${PORT}:\\" > printcap.remote
- echo " :lp=:rm=${HOST}:rp=${PRINTER}:sd=${NEWSPOOLDIR}:" >> printcap.remote
-
- sharfile: README Makefile servercomm.8l servercomm.c hello.ps example
- shar README Makefile servercomm.8l servercomm.c hello.ps example > sharfile
-