Howto configure network Postscript printer under YDL 2.0


Subject: Howto configure network Postscript printer under YDL 2.0
From: Stephen Lewis (lewis@napanet.net)
Date: Mon Jul 23 2001 - 09:28:13 MDT


Re: Problems configuring an Appletalk Printer w/ YDL 2.0 (newbie)
Re: pap/netatalk problem

This explains how to fix two problems associated with
Postscript printers using Netatalk on YDL 2.0

Problem Number One: The "Bad status" message.
"Use the Source Luke!"
The current PAP implementation seems a might too picky
and gives this message for several Laserwriters including
Apple IINTX. I don't know about GCC IIS but its worth
trying this which fixed my IINTX. It involves a small
change to 'pap.c' and recompiling it.
# How I fixed 'pap' for my LW IINTX
# As root proced as follows:
# Insert YDL 2.0 Source CD
mount /dev/cdrom
cd /mnt/cdrom
cd Yello*/SRPMS
rpm -i netatalk*
cd /usr/src/rpm/SPECS
rpm -bc netatalk*
cd ../BUILD/netatalk*
cd bin/pap
cp pap.c pap.c-
# Edit the file pap.c and insert following define near the top:
-----------------------------------------------------------
#define NONZEROSTATUS
-----------------------------------------------------------
make
make install
# Now login as a user and try:
pap -p "Your Printer Here" file.ps

If this does not work there are only four places
in 'pap.c' that generate the message - try looking at the
others. Assuming that did work, on to the second problem.

Problem Number Two: How to tell the 'lpr' spooler about your printer.
There are several bugs in the new (YDL 2.0/RH 7) implemantation
of 'printtool' and its buddies including the "master-filter".
But it can be persuaded to work as follows:

You can begin with 'printtool'
Use 'printtool' choose 'Add' then 'Local Printer' (ignore message
about didn't find a device - this is OK)

Enter -> Names=lp|LaserWriterWhatever
        Spool Directory=/var/spool/lpd/lp
        File Limit=0
Enter -> Printer Device=/dev/null
Input Filter press "Select"
Choose -> Postscript
press OK

Then "Restart LPD" from lpd menu

and exit printtool which has done 90% of what you need
Unfortunately printtool doesn't know about PAP printers,
fortunately the "master-filter" does.

So edit
/var/spool/lpd/lp/general.cfg and change "LOCAL" to "ATALK"
then put your '.paprc' file in /var/spool/lpd/lp

***NOTE*** although 'man pap' says comment lines are
ignored the 'master-filter' tries to use the whole
file as an arg to pap (completely bogus!!) so the "new"
format for content of .paprc is:
------------------------
"Apple Name of Printer"
------------------------
file should be one line, no comments and you DO need the quotes.

and then try:
lpr -P lp file.txt
lpr -P lp file.ps
and try printing from inside applications - it *should* all work,
This worked for me, final printcap looks like this, good luck,

##PRINTTOOL3## LOCAL POSTSCRIPT 300x300 letter {} PostScript Default
{}
lp|LaserWriterWhatever:\
        :sd=/var/spool/lpd/lp:\
        :mx#0:\
        :sh:\
        :lp=/dev/null:\
        :if=/var/spool/lpd/lp/filter:

Stephen Lewis



This archive was generated by hypermail 2a24 : Mon Jul 23 2001 - 09:29:57 MDT