GNOME Bugzilla – Bug 585399
Build failure: missing #include for XK_Escape
Last modified: 2011-06-13 20:44:27 UTC
Building gnome-utils-2.26.0 on OS X 10.4 with apple's x11 and all other external support via fink at the level of GNOME2.26 fails: gcc -DHAVE_CONFIG_H -I. -I.. -I. -I. -DGNOMELOCALEDIR=\""/sw/share/locale"\" -DUIDIR=\""/sw/share/gnome-screenshot"\" -I/sw/lib/fontconfig2/include -I/sw/include/glib-2.0 -I/sw/lib/glib-2.0/include -I/sw/include/gconf/2 -I/sw/include/orbit-2.0 -I/sw/include/dbus-1.0 -I/sw/lib/dbus-1.0/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/pixman-1 -I/sw/include/freetype2 -I/sw/include -I/sw/include/libpng12 -I/usr/X11R6/include -I/usr/X11/include -DORBIT2=1 -I/sw/include/glib-2.0 -I/sw/lib/glib-2.0/include -I/sw/include -Os -fno-common -c screenshot-utils.c screenshot-utils.c: In function 'select_area_filter': screenshot-utils.c:361: error: 'XK_Escape' undeclared (first use in this function) screenshot-utils.c:361: error: (Each undeclared identifier is reported only once screenshot-utils.c:361: error: for each function it appears in.) make[2]: *** [screenshot-utils.o] Error 1 Need to #include <X11/keysymdef.h> to get a keysym name, and need to #define XK_MISCELLANY (per XLib manpage, and confirmed by testing) to activate that set of kysym defs.
Created attachment 136309 [details] [review] XK_Escape.patch
Alternative is simply to #include <X11/keysym.h>, which does all the necessary #defines and then loads the actual keysymdef.h
That code changed recently, and doesn't use XLib directly anymore. Closing as OBSOLETE.