[cups-devel] Printer Setup Tools and deprecated PPD API

Michael Sweet msweet at apple.com
Tue May 16 07:18:58 PDT 2017


Till,

> On May 16, 2017, at 9:56 AM, Till Kamppeter <till.kamppeter at gmail.com> wrote:
> 
> On 05/16/2017 09:01 AM, Michael Sweet wrote:
>>> The backends planned for now (and under development in the GSoC) are:
>>> 
>>> 1. CUPS backend - Uses CUPS APIs of new CUPS Programmers Manual, no PPD API. Lists the (permanent-only?) CUPS queues of the local CUPS daemon.
>>> 
>>> 2. IPP backend - Lists printers discovered by DNS-SD, IPP network printers, IPP-over-USB printers, and remote CUPS queues, when the user selects one to print on, a temporary CUPS queue is created so that options can be displayed and the job be sent.
>> 
>> Sigh...  If you just use the published CUPS APIs you get 1 and 2 automatically!
>> 
> 
> My impression was that the APIs make up the CUPS backend (1), listing the available CUPS queues (whether permanent or temporary would be user-selectable) and acting on these when asking for options or sending jobs.
> 
> Does it mean that if I fire up the CUPS daemon (no temporary queues), having an empty printers.conf (no permanent queues) and immediately call a CUPS API function (which one?) I get a list of all printers discoverable via DNS-SD (IPP network printers, IPP-over-USB printers reported by ippusbxd, remote CUPS queues)? And when I try to access them via CUPS API functions (which ones?) CUPS generates a temporary queue with auto-generated PPD and then answers my request (list available options, take print job and execute it, ...)?

The cupsEnumDests API lists both existing cupsd queues and those discovered via other means - currently just DNS-SD, but we also plan to re-add LDAP support at some point in the future as well as support "configuration profiles" where you could deploy static files (through things like "puppet", etc.) that list other printers on the network that cannot be discovered via other means, "follow me" print servers, etc.  (FWIW, this has been on my CUPS printing summit slides since 2012!)

Once you have a destination, use one of the "dest" APIs (cupsCreateDestJob, cupsCopyDestInfo, etc.) to work with it.  In the case of cupsCreateDestJob, it handles automatically creating a local (temporary) queue as needed (starting with CUPS 2.2).

_________________________________________________________
Michael Sweet, Senior Printing System Engineer



More information about the cups-devel mailing list