--- rxvt-unicode/configure.ac 2010/07/22 15:42:49 1.112 +++ rxvt-unicode/configure.ac 2010/10/31 08:28:01 1.120 @@ -96,7 +96,6 @@ support_scroll_xterm=yes support_xim=yes support_afterimage=yes -support_afterstep=yes support_xft=yes support_unicode3=no support_combining=yes @@ -132,7 +131,6 @@ support_wtmp=no support_xim=no support_afterimage=no - support_afterstep=no support_xft=no support_unicode3=no support_combining=no @@ -160,7 +158,6 @@ support_wtmp=yes support_xim=yes support_afterimage=yes - support_afterstep=yes support_xft=yes support_unicode3=yes support_combining=yes @@ -244,11 +241,11 @@ afterimage_config=$withval/afterimage-config fi]) -dnl AC_ARG_ENABLE(afterstep, -dnl [ --enable-afterstep enable integration with AfterStep window manager], -dnl [if test x$enableval = xyes -o x$enableval = xno; then -dnl support_afterstep=$enableval -dnl fi]) +AC_ARG_ENABLE(pixbuf, + [ --enable-pixbuf enable integration with gdk-pixbuf for background images], + [if test x$enableval = xyes -o x$enableval = xno; then + support_pixbuf=$enableval + fi]) AC_ARG_ENABLE(transparency, [ --enable-transparency enable transparent backgrounds], @@ -351,7 +348,6 @@ [RXVTNAME="$withval"]) AC_DEFINE_UNQUOTED(RXVTNAME,"$RXVTNAME", [Binary base name]) -RXVTNAME=`echo "$RXVTNAME"|sed "$program_transform_name"` AC_SUBST(RXVTNAME) AC_ARG_ENABLE(swapscreen, @@ -437,6 +433,35 @@ AC_PATH_XTRA +image_lib=none + +PIXBUF_CFLAGS= +PIXBUF_LIBS= + +if test x$support_pixbuf = xyes; then + support_pixbuf=no + AC_PATH_PROG(PKG_CONFIG, pkg-config, no) + AC_MSG_CHECKING(for gdk-pixbuf) + if test $PKG_CONFIG != no && $PKG_CONFIG --exists gdk-pixbuf-xlib-2.0; then + PIXBUF_CFLAGS="`$PKG_CONFIG gdk-pixbuf-xlib-2.0 --cflags`" + PIXBUF_LIBS="`$PKG_CONFIG gdk-pixbuf-xlib-2.0 --libs`" + support_pixbuf=yes + fi + + if test x$support_pixbuf = xyes; then + AC_MSG_RESULT(ok) + image_lib=gdk-pixbuf + support_afterimage=no + AC_DEFINE(HAVE_PIXBUF, 1, Define if you want to use gdk-pixbuf for image processing) + AC_DEFINE(BG_IMAGE_FROM_FILE, 1, Define if you want to have sexy-looking background pixmaps.) + else + AC_MSG_RESULT(no) + fi +fi + +AC_SUBST(PIXBUF_CFLAGS) +AC_SUBST(PIXBUF_LIBS) + AFTERIMAGE_CFLAGS= AFTERIMAGE_LIBS= AFTERIMAGE_VERSION= @@ -466,12 +491,18 @@ fi if test "x$support_afterimage" = "xyes"; then AC_MSG_RESULT($AFTERIMAGE_LIBS) + image_lib=libafterimage + AC_DEFINE(HAVE_AFTERIMAGE, 1, Define if you want to use libAfterImage for image processing) + AC_DEFINE(BG_IMAGE_FROM_FILE, 1, Define if you want to have sexy-looking background pixmaps.) else AC_MSG_RESULT(no) fi fi fi +AC_SUBST(AFTERIMAGE_CFLAGS) +AC_SUBST(AFTERIMAGE_LIBS) + dnl# -------------------------------------------------------------------------- dnl# CHECKING FOR HEADER FILES dnl# -------------------------------------------------------------------------- @@ -620,6 +651,25 @@ AC_DEFINE(XFT, 1, Define to enable xft support) fi fi +if test x$support_inheritpixmap = xyes; then + support_xrender=yes + AC_PATH_PROG(PKG_CONFIG, pkg-config, no) + if test $PKG_CONFIG != no && $PKG_CONFIG --exists xrender; then + X_LIBS="`$PKG_CONFIG xrender --libs` $X_LIBS" + CPPFLAGS="$CPPFLAGS `$PKG_CONFIG xrender --cflags`" + + save_LIBS="$LIBS" + LIBS="$LIBS $X_LIBS" + AC_CHECK_HEADER(X11/extensions/Xrender.h,,[support_xrender=no]) + AC_CHECK_FUNC(XRenderFindStandardFormat,,[support_xrender=no]) + LIBS="$save_LIBS" + fi + + if test x$support_xrender = xyes; then + LIBS="$LIBS -lm" + AC_DEFINE(XRENDER, 1, Define to enable xrender support) + fi +fi if test x$support_styles = xyes; then AC_DEFINE(ENABLE_STYLES, 1, Define if you want bold and italic support) fi @@ -650,14 +700,6 @@ if test x$support_mouseslipwheel = xyes; then AC_DEFINE(MOUSE_SLIP_WHEELING, 1, Define to have CTRL cause wheel events to accelerate scrolling. Release CTRL to halt scrolling) fi -if test x$support_afterimage = xyes; then - AC_DEFINE(HAVE_AFTERIMAGE, 1, Define if you want to use libAfterImage for image processing) - AC_DEFINE(BG_IMAGE_FROM_FILE, 1, Define if you want to have sexy-looking background pixmaps. Needs libAfterImage) -fi - -dnl if test x$support_afterstep = xyes; then -dnl AC_DEFINE(AFTERSTEP_INTEGRATION, 1, Define if you want to integrate with AfterStep window manager) -dnl fi scrolltypes=plain AC_DEFINE(PLAIN_SCROLLBAR, 1, Support plain style scrollbars) @@ -675,7 +717,7 @@ scrolltypes="$scrolltypes xterm" fi if test x$support_pointer_blank = xyes; then - AC_DEFINE(POINTER_BLANK, 1, Define if you want hide the pointer while typing) + AC_DEFINE(POINTER_BLANK, 1, Define if you want to hide the pointer while typing) fi if test x$support_text_blink = xyes; then AC_DEFINE(TEXT_BLINK, 1, Define if you want blinking text support) @@ -746,13 +788,6 @@ AC_SUBST(PERL_O) -dnl# Attack the libs - -AC_SUBST(AFTERIMAGE_CFLAGS) -AC_SUBST(AFTERIMAGE_LIBS) - -AC_ARG_PROGRAM - AC_CONFIG_FILES([Makefile \ doc/Makefile \ src/Makefile \ @@ -781,8 +816,7 @@ fi echo echo " embedded perl: $support_perl" -echo " libafterimage: $support_afterimage" -dnl echo " AfterStep integration: $support_afterstep" +echo " image library: $image_lib" echo if test x$support_xim = xyes -a x$rxvt_cv_func_xlocale = xno; then echo ".----------------------------------------------------------------."