I'm having a field day with CUPS-Xprint bugs today. Maybe we need a tracking bug to follow them all? The tracking bug would also want to link to the earlier bug about picking up printer capabilities from CUPS, from the CUPS ppd file. Anyway, this particular Debian bug #229255 (see also #263541) says that the printer spool's default printer ought to be recognised by Xprint, without having to separately configure Xprint or set the environment variable XPRINTER. It might be that this question is relevant to the other printer spools too, not just CUPS. Bug #229255 suggests a patch for our /etc/X11/Xsession.d script, which I think I will include in Debian's version: --- 92xprint-xpserverlist 2004-01-15 01:22:00.000000000 -0600 +++ mod 2004-01-23 15:34:52.000000000 -0600 @@ -27,4 +27,15 @@ export XPSERVERLIST fi + +# If no defalt printer is defined, get default printer +# from lp system +if [ -z "$XPRINTER" ]; then + if lpstat -d > /dev/null; then + PRINTER=`lpstat -d | sed -e 's/^[^:]\+: \(.*\)$/\1/'` + SERVER_ARRAY=( $XPSERVERLIST ) + export XPRINTER="${PRINTER}@${SERVER_ARRAY[0]}" + fi +fi + ########################## eof #####################
By the way, I think this little patch is not adequate on its own. If there is no default printer defined in CUPS, then lpstat -d returns "no default printer", and so XPRINTER gets set by this patch to "no default printer", which isn't much good.
Closing WONTFIX because nobody cares about Xprint. Reopen if you plan to address this bug.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.