emacs-22.2-r2 fails to configure when cairo is built without X use flag. use flags: emacs: (X Xaw3d alsa gif gtk jpeg kerberos png spell tiff toolkit-scroll-bars xpm -gzip-el -hesiod -motif -sound -source) cairo: (opengl svg -X -debug -directfb -doc -glitz -test -xcb)
configure output snippet: checking for XScreenNumberOfScreen... yes checking for XSetWMProtocols... yes checking X11 version 6... 6 or newer checking X11 version 5... 5 or newer checking for gtk+-2.0 >= 2.6 glib-2.0 >= 2.6... yes checking GTK_CFLAGS... -I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng12 -I/usr/include/pixman-1 checking GTK_LIBS... -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lpango-1.0 -lcairo -lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0 checking for gtk_main... no configure: error: Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?
Discovered because of bug 225215.
@Marijn: You should really assign bugs yourself. You have the power! :)
All ebuilds of x11-libs/gtk+-2* have the following test in their pkg_setup: if ! built_with_use x11-libs/cairo X; then eerror "Please re-emerge x11-libs/cairo with the X USE flag set" die "cairo needs the X flag set" fi So, to reproduce the bug, you must: 1. emerge cairo with USE="X" 2. emerge gtk+ 3. emerge cairo again, this time with USE="-X" 4. emerge emacs with USE="X gtk" I think the test in the gtk+ ebuild is sufficient and we don't have to add it to the emacs ebuild.