After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 574065 - Setup printers
Setup printers
Status: RESOLVED OBSOLETE
Product: gnome-bluetooth
Classification: Core
Component: general
unspecified
Other Linux
: Normal enhancement
: ---
Assigned To: gnome-bluetooth-general-maint@gnome.bugs
gnome-bluetooth-general-maint@gnome.bugs
Depends on: 575414
Blocks:
 
 
Reported: 2009-03-04 13:22 UTC by Bastien Nocera
Modified: 2019-03-20 10:35 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Example use of cupshelpers.ppds.PPDs.getPPDNameFromDeviceID (569 bytes, text/plain)
2009-03-05 20:22 UTC, Bastien Nocera
Details

Description Bastien Nocera 2009-03-04 13:22:19 UTC
We'd need to do something similar to what hal-cups-utils does:
https://fedorahosted.org/hal-cups-utils/

When the device is setup, we can call the com.redhat.NewPrinterNotification API, passing the device URI as the 'name' argument to NewPrinter().
When the device is removed (eg. through the preferences), we'd need to remove the queue.

When the bluez cups backend can support getting the IEEE1284 for a specific device, we can use something similar to hal-cups-utils (see cupshelpers.ppds.PPDs.getPPDNameFromDeviceID) to guess the PPD for it.

Then we'd call:
lpadmin -p "${NAME}" -v "${URI}" -m "${PPDNAME}"
Comment 1 Bastien Nocera 2009-03-05 20:22:08 UTC
Created attachment 130151 [details]
Example use of cupshelpers.ppds.PPDs.getPPDNameFromDeviceID

2 problems I could see. It's very very expensive to run (although we can work around that in the UI, is there a cache somewhere?), and it prints out debug.
Comment 2 Bastien Nocera 2009-07-27 00:26:02 UTC
We could make this easier by installing a bluez driver that checks for the HCRP UUID, and install a GetProperties for it. We could even have it give the PPD name by using the D-Bus helper script.

So on the gnome-bluetooth side we would:
- check for HCRP
- get the properties on the Printer service
- launch lpadmin (or equivalent)
Comment 3 Bastien Nocera 2010-08-03 17:07:37 UTC
Actually, see:
https://fedorahosted.org/system-config-printer/ticket/207

You'll need this patch to bluez:
http://thread.gmane.org/gmane.linux.bluez.kernel/5879

This allows system-config-printer to do most of the work.
Comment 4 Bastien Nocera 2010-09-01 15:21:13 UTC
BlueZ patch was updated.

Last udev-configure-printer patch is at:
https://fedorahosted.org/system-config-printer/ticket/211

Still needed is a bluetoothd plugin to launch "udev-configure-printer add/remove bdaddr", and some integration in gnome-bluetooth (offer a "Setup printer" button in properties, disabled if queue is already available, launch "New printer"[1] when clicked).

[1]: https://fedorahosted.org/pipermail/system-config-printer-devel/2010-April/000003.html
Comment 5 GNOME Infrastructure Team 2019-03-20 10:35:31 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gnome-bluetooth/issues/12.