GNOME Bugzilla – Bug 611670
Some xinput use not protected by autoconf test for xinput
Last modified: 2010-10-12 18:55:07 UTC
Building g-s-d-2.28.1 on OS X 10.4/ppc, -lXi was correctly not-detected during ./configure (per resolution of Bug #585315). Build fails in plugins/mouse: /bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I../.. -I../../gnome-settings-daemon -DGNOME_SETTINGS_LOCALEDIR=\""/sw/share/locale"\" -I/sw/lib/fontconfig2/include -I/sw/include -I/sw/include -I/usr/X11R6/include -I/sw/include -I/usr/X11R6/include -I/sw/lib/fontconfig2/include -I/sw/include/gtk-2.0 -I/sw/lib/gtk-2.0/include -I/sw/include/atk-1.0 -I/sw/include/cairo -I/sw/include/pango-1.0 -I/sw/include/glib-2.0 -I/sw/lib/glib-2.0/include -I/sw/include/pixman-1 -I/sw/include/freetype2 -I/sw/include -I/sw/include/gconf/2 -I/sw/include/gnome-desktop-2.0 -I/sw/include/startup-notification-1.0 -I/sw/include/dbus-1.0 -I/sw/lib/dbus-1.0/include -I/usr/X11R6/include -I/usr/X11/include -Os -pipe -MT libmouse_la-gsd-mouse-manager.lo -MD -MP -MF .deps/libmouse_la-gsd-mouse-manager.Tpo -c -o libmouse_la-gsd-mouse-manager.lo `test -f 'gsd-mouse-manager.c' || echo './'`gsd-mouse-manager.c libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../gnome-settings-daemon -DGNOME_SETTINGS_LOCALEDIR=\"/sw/share/locale\" -I/sw/lib/fontconfig2/include -I/sw/include -I/sw/include -I/usr/X11R6/include -I/sw/include -I/usr/X11R6/include -I/sw/lib/fontconfig2/include -I/sw/include/gtk-2.0 -I/sw/lib/gtk-2.0/include -I/sw/include/atk-1.0 -I/sw/include/cairo -I/sw/include/pango-1.0 -I/sw/include/glib-2.0 -I/sw/lib/glib-2.0/include -I/sw/include/pixman-1 -I/sw/include/freetype2 -I/sw/include -I/sw/include/gconf/2 -I/sw/include/gnome-desktop-2.0 -I/sw/include/startup-notification-1.0 -I/sw/include/dbus-1.0 -I/sw/lib/dbus-1.0/include -I/usr/X11R6/include -I/usr/X11/include -Os -pipe -MT libmouse_la-gsd-mouse-manager.lo -MD -MP -MF .deps/libmouse_la-gsd-mouse-manager.Tpo -c gsd-mouse-manager.c -fno-common -DPIC -o .libs/libmouse_la-gsd-mouse-manager.o gsd-mouse-manager.c:87: error: parse error before '*' token gsd-mouse-manager.c:87: error: parse error before 'deviceinfo' gsd-mouse-manager.c:87: warning: data definition has no type or storage class gsd-mouse-manager.c:463: error: parse error before '*' token gsd-mouse-manager.c:464: error: parse error before 'deviceinfo' gsd-mouse-manager.c: In function 'device_is_touchpad': gsd-mouse-manager.c:466: error: 'XDevice' undeclared (first use in this function) gsd-mouse-manager.c:466: error: (Each undeclared identifier is reported only once gsd-mouse-manager.c:466: error: for each function it appears in.) gsd-mouse-manager.c:466: error: 'device' undeclared (first use in this function) gsd-mouse-manager.c:472: error: 'deviceinfo' undeclared (first use in this function) gsd-mouse-manager.c:472: error: 'XI_TOUCHPAD' undeclared (first use in this function) gsd-mouse-manager.c: In function 'set_tap_to_click': gsd-mouse-manager.c:547: error: 'XDeviceInfo' undeclared (first use in this function) gsd-mouse-manager.c:547: error: 'devicelist' undeclared (first use in this function) gsd-mouse-manager.c:548: error: 'XDevice' undeclared (first use in this function) gsd-mouse-manager.c:548: error: 'device' undeclared (first use in this function) gsd-mouse-manager.c: In function 'set_horiz_scroll': gsd-mouse-manager.c:595: error: 'XDeviceInfo' undeclared (first use in this function) gsd-mouse-manager.c:595: error: 'devicelist' undeclared (first use in this function) gsd-mouse-manager.c:596: error: 'XDevice' undeclared (first use in this function) gsd-mouse-manager.c:596: error: 'device' undeclared (first use in this function) gsd-mouse-manager.c: In function 'set_edge_scroll': gsd-mouse-manager.c:662: error: 'XDeviceInfo' undeclared (first use in this function) gsd-mouse-manager.c:662: error: 'devicelist' undeclared (first use in this function) gsd-mouse-manager.c:663: error: 'XDevice' undeclared (first use in this function) gsd-mouse-manager.c:663: error: 'device' undeclared (first use in this function) make[3]: *** [libmouse_la-gsd-mouse-manager.lo] Error 1 Those are places where xinput use is not controlled by HAVE_X11_EXTENSIONS_XINPUT_H. That token *does* control #include for XInput.h, so definitely nothing prototyped in there will be available if that token isn't defined. It looks like the unshielded uses are from the addition of the touchpad stuff http://git.gnome.org/browse/gnome-settings-daemon/commit/?id=4eb9bd09219afbb56f114a2d10bc585e24db803e http://git.gnome.org/browse/gnome-settings-daemon/commit/?id=6a3bedfcb9be30b883a145d7e4ce83fd9cbc3e25 I think.
Created attachment 155101 [details] [review] Use autoconf token to avoid using xinput if it doesn't exist
If you could provide a patch against current trunk that'd be helpful. Otherwise you'll just bump into this again with the next version...
Created attachment 155527 [details] [review] Use autoconf token to avoid using xinput if it doesn't exist (against trunk) As requested. This also #ifdef's out some gconf tokens that are only used in that #ifdef'ed code (pedantic/self-consistency cleanup).
Review of attachment 155101 [details] [review]: This one doesn't apply to the 2.28 branch.
XInput is now a requirement for gnome-settings-daemon 3.x