From owner-freebsd-questions Fri Dec 15 14:40:05 1995 Return-Path: owner-questions Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id OAA23383 for questions-outgoing; Fri, 15 Dec 1995 14:40:05 -0800 (PST) Received: from central.picker.com (central.picker.com [144.54.31.2]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id OAA23347 for ; Fri, 15 Dec 1995 14:39:56 -0800 (PST) Received: from ct.picker.com by central.picker.com with smtp (Smail3.1.28.1 #3) id m0tQiXj-0004wqC; Fri, 15 Dec 95 17:23 EST Received: from elmer.ct.picker.com ([144.54.52.5]) by ct.picker.com (4.1/SMI-4.1) id AA08470; Fri, 15 Dec 95 17:23:30 EST Received: by elmer.ct.picker.com (5.0/SMI-SVR4) id AA10309; Fri, 15 Dec 1995 17:19:59 +0500 From: rhh@ct.picker.com (Randall Hopper) Message-Id: <9512152219.AA10309@elmer.ct.picker.com> Subject: Re: Printing in FreeBSD To: questions@FreeBSD.org Date: Fri, 15 Dec 1995 17:19:59 -0500 (EST) Reply-To: rhh@ct.picker.com Organization: Picker International, CT Division X-Mailer: ELM [version 2.4 PL24 PGP3 *ALPHA*] Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-questions@FreeBSD.org Precedence: bulk > > Okay. Question on printing with FreeBSD, sans ghostscript. The system > > is FreeBSD v2.1.0, i'm catting files to /dev/lpt0. The files come out in > > Is there a peculiar reason why you don't use > lpd printing (/etc/printcap)? > > Either you add a filter to /etc/printcap (apsfilter e.g. or a simple shell > script or C-program) ) or you send your printer > the sequence to make it understand the carriage control. > > Here is a snippet that someone else grabbed drom usenet: > This issue is overdue to find reflection in the FAQ > if it isnt't yet. I posted the printcap & ghostscript scripts quoted here (printcap was one I hacked from the 386BSD FAQ). I have since tweaked them a little; the raw (lp) queue is now just that, the printer now does EOL conversion instead of unix2dos program, etc. Nothing big. Here's the new version and script file I'm using for printing on an HP Laserjet 4P w/o Postscript SIMM. ------------------------------/etc/printcap----------------------------------- # @(#)printcap 5.3 (Berkeley) 6/30/90 lp|LJ4P (Raw):\ :lp=/dev/lpt0:sd=/usr/var/spool/lpd:lf=/var/log/lpd-errs:\ :mx#0:ff=\033E:fo:sh:tr=\033E: text|LJ4P (w/ UNIX->DOS EOL text conversion):\ :lp=/dev/lpt0:sd=/usr/var/spool/lpd:lf=/var/log/lpd-errs:\ :mx#0:ff=\033E\033&k2G:fo:sh:tr=\033E: ps|LJ4P (w/ Ghostscript PS->PCL conversion):\ :lp=/dev/null:sd=/usr/var/spool/lpd:lf=/var/log/lpd-errs:\ :of=/usr/local/bin/gslj:\ :mx#0:sf:sh: ----------------------------/usr/local/bin/gslj-------------------------------- #!/bin/sh TMPDIR=/usr/tmp PRINTER=lp GSLIB=/usr/local/lib/ghostscript/fonts PATH=/usr/local/bin:/usr/bin:$PATH export TMPDIR PRINTER GSLIB PATH exec gs -q -sDEVICE=ljet4 -dNOPAUSE -sOutputFile=\|lpr gslp.ps -