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 592364 - Use GUdev rather than deprecated HAL for GIMP
Use GUdev rather than deprecated HAL for GIMP
Status: RESOLVED FIXED
Product: GIMP
Classification: Other
Component: General
git master
Other All
: Normal normal
: 2.8
Assigned To: GIMP Bugs
GIMP Bugs
Depends on: 596725
Blocks: 593938
 
 
Reported: 2009-08-19 18:07 UTC by matthaeus123
Modified: 2011-06-23 14:36 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description matthaeus123 2009-08-19 18:07:52 UTC
Please support devicekit, because hal is no longer in development and is deprecated in favor of devicekit.
Comment 1 Martin Nordholts 2009-08-19 19:27:09 UTC
Confirming and setting milestone Future.
Comment 2 Martin Nordholts 2009-08-19 19:29:17 UTC
DeiceKit home page:
http://www.freedesktop.org/wiki/Software/DeviceKit
Comment 3 Sven Neumann 2009-08-20 18:51:27 UTC
Feel free to attach a patch that ports the module to devicekit.
Comment 4 Javier Jardón (IRC: jjardon) 2009-09-02 16:44:11 UTC
For the record:

$ git grep libhal
modules/gimpinputdevicestore-dx.c:  GimpInputDeviceStore *store = libhal_ctx_get_user_data (ctx);
modules/gimpinputdevicestore-dx.c:  GimpInputDeviceStore *store = libhal_ctx_get_user_data (ctx);
modules/gimpinputdevicestore-hal.c:#include <hal/libhal.h>
modules/gimpinputdevicestore-hal.c:  store->context = libhal_ctx_new ();
modules/gimpinputdevicestore-hal.c:  libhal_ctx_set_dbus_connection (store->context,
modules/gimpinputdevicestore-hal.c:  if (libhal_ctx_init (store->context, &dbus_error))
modules/gimpinputdevicestore-hal.c:      devices = libhal_find_device_by_capability (store->context, "input",
modules/gimpinputdevicestore-hal.c:      libhal_free_string_array (devices);
modules/gimpinputdevicestore-hal.c:      libhal_ctx_set_user_data (store->context, store);
modules/gimpinputdevicestore-hal.c:      libhal_ctx_set_device_added (store->context,
modules/gimpinputdevicestore-hal.c:      libhal_ctx_set_device_removed (store->context,
modules/gimpinputdevicestore-hal.c:      libhal_ctx_free (store->context);
modules/gimpinputdevicestore-hal.c:      libhal_ctx_shutdown (store->context, NULL);
modules/gimpinputdevicestore-hal.c:      libhal_ctx_free (store->context);
modules/gimpinputdevicestore-hal.c:  caps = libhal_device_get_property_strlist (store->context,
modules/gimpinputdevicestore-hal.c:      str = libhal_device_get_property_string (store->context,
modules/gimpinputdevicestore-hal.c:          libhal_free_string (str);
modules/gimpinputdevicestore-hal.c:      str = libhal_device_get_property_string (store->context,
modules/gimpinputdevicestore-hal.c:          libhal_free_string (str);
modules/gimpinputdevicestore-hal.c:  libhal_free_string_array (caps);
modules/gimpinputdevicestore-hal.c:  GimpInputDeviceStore *store = libhal_ctx_get_user_data (ctx);
modules/gimpinputdevicestore-hal.c:  GimpInputDeviceStore *store = libhal_ctx_get_user_data (ctx);
modules/gimpinputdevicestore-hal.c:      char *str = libhal_device_get_property_string (store->context,
modules/gimpinputdevicestore-hal.c:          libhal_free_string (str);
Comment 5 Michael Natterer 2009-09-02 17:53:22 UTC
We know where we use hal :) Why don't you attach a patch that ports
the code to devicekit?
Comment 6 Bastien Nocera 2009-11-10 19:52:42 UTC
Wouldn't this be completely obsoleted by a GTK+ using XI2 (thus allowing hotplug devices, device enumeration and access to all the keys on devices)?
Comment 7 Sven Neumann 2009-11-10 22:50:27 UTC
Yes, probably. The linux-input module in GIMP is really just a hack. But it's a nice hack for people who would like to play with fancy input devices. However ff someone wants to improve this, feel free to send your patches.
Comment 8 Javier Jardón (IRC: jjardon) 2010-01-12 02:36:27 UTC
CC'ing Garnacho as he should have some good overview here.
Comment 9 Carlos Garnacho 2010-01-18 10:25:41 UTC
If libhal is just used for input devices, it should be definitely replaceable by my XI2 work, in the xi2 branch there is a GdkDeviceManager object, with device-added and device-removed signals, so keeping track of changes in the device hierarchy should be quite easy.
Comment 10 Michael Natterer 2011-06-23 14:30:23 UTC
DeviceKit is now obsolete too, so -> GUdev
Comment 11 Michael Natterer 2011-06-23 14:35:54 UTC
Fixed in master:

commit f1bb40166b1061f630fab615f658310c25abf423
Author: Michael Natterer <mitch@gimp.org>
Date:   Thu Jun 23 16:30:58 2011 +0200

    Bug 592364 - Use GUdev rather than deprecated HAL for GIMP
    
    GIMP was probably the only user of libhal on most systems, this had
    to stop. Ported the linux-input module to GUdev.

 configure.ac                         |   30 ++--
 modules/Makefile.am                  |    6 +-
 modules/controller-linux-input.c     |    8 +-
 modules/gimpinputdevicestore-gudev.c |  433 ++++++++++++++++++++++++++++++++
 modules/gimpinputdevicestore-hal.c   |  459 ----------------------------------
 5 files changed, 455 insertions(+), 481 deletions(-)