diff --git a/ChangeLog b/ChangeLog index 4fcf1513b..6b175c736 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2004-02-14 Rob Adams + + * configure.in: Add configure option to not even try using + xinerama, to make metacity buildable on systems with no shared + library version of the xinerama libraries. Patch for #134203 from + Julio M. Merino Vidal. + 2004-02-01 Rob Adams * COMPLIANCE: Bring up to date with current draft EWHM. diff --git a/configure.in b/configure.in index 6a6a34999..daebbf3e1 100644 --- a/configure.in +++ b/configure.in @@ -213,46 +213,51 @@ ALL_X_LIBS="$X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS" metacity_save_cppflags="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $X_CFLAGS" +AC_ARG_ENABLE(xinerama,[ --disable-xinerama disable metacity's use of the Xinerama extension], + try_xinerama=no,try_xinerama=yes) + use_solaris_xinerama=no use_xfree_xinerama=no -case "$host" in - *-*-solaris*) - # Check for solaris - use_solaris_xinerama=yes - AC_CHECK_LIB(Xext, XineramaGetInfo, - use_solaris_xinerama=yes, use_solaris_xinerama=no, - $ALL_X_LIBS) - if test "x$use_solaris_xinerama" = "xyes"; then - AC_CHECK_HEADER(X11/extensions/xinerama.h, - if test -z "`echo $ALL_X_LIBS | grep "\-lXext" 2> /dev/null`"; then - X_EXTRA_LIBS="-lXext $X_EXTRA_LIBS" - fi - AC_DEFINE(HAVE_SOLARIS_XINERAMA, , [Have Solaris-style Xinerama]) - AC_DEFINE(HAVE_XINERAMA, , [Have some version of Xinerama]), - use_solaris_xinerama=no, - [#include ]) - fi - AC_MSG_CHECKING(for Xinerama support on Solaris) - AC_MSG_RESULT($use_solaris_xinerama); - ;; - *) - # Check for XFree - use_xfree_xinerama=yes - AC_CHECK_LIB(Xinerama, XineramaQueryExtension, - [AC_CHECK_HEADER(X11/extensions/Xinerama.h, - X_EXTRA_LIBS="-lXinerama $X_EXTRA_LIBS" - if test -z "`echo $ALL_X_LIBS | grep "\-lXext" 2> /dev/null`"; then - X_EXTRA_LIBS="-lXext $X_EXTRA_LIBS" - fi - AC_DEFINE(HAVE_XFREE_XINERAMA, , [Have XFree86-style Xinerama]) - AC_DEFINE(HAVE_XINERAMA,, [Have some version of Xinerama]), - use_xfree_xinerama=no, - [#include ])], - use_xfree_xinerama=no, -lXext $ALL_X_LIBS) - AC_MSG_CHECKING(for Xinerama support on XFree86) - AC_MSG_RESULT($use_xfree_xinerama); - ;; -esac +if test "${try_xinerama}" != no; then + case "$host" in + *-*-solaris*) + # Check for solaris + use_solaris_xinerama=yes + AC_CHECK_LIB(Xext, XineramaGetInfo, + use_solaris_xinerama=yes, use_solaris_xinerama=no, + $ALL_X_LIBS) + if test "x$use_solaris_xinerama" = "xyes"; then + AC_CHECK_HEADER(X11/extensions/xinerama.h, + if test -z "`echo $ALL_X_LIBS | grep "\-lXext" 2> /dev/null`"; then + X_EXTRA_LIBS="-lXext $X_EXTRA_LIBS" + fi + AC_DEFINE(HAVE_SOLARIS_XINERAMA, , [Have Solaris-style Xinerama]) + AC_DEFINE(HAVE_XINERAMA, , [Have some version of Xinerama]), + use_solaris_xinerama=no, + [#include ]) + fi + AC_MSG_CHECKING(for Xinerama support on Solaris) + AC_MSG_RESULT($use_solaris_xinerama); + ;; + *) + # Check for XFree + use_xfree_xinerama=yes + AC_CHECK_LIB(Xinerama, XineramaQueryExtension, + [AC_CHECK_HEADER(X11/extensions/Xinerama.h, + X_EXTRA_LIBS="-lXinerama $X_EXTRA_LIBS" + if test -z "`echo $ALL_X_LIBS | grep "\-lXext" 2> /dev/null`"; then + X_EXTRA_LIBS="-lXext $X_EXTRA_LIBS" + fi + AC_DEFINE(HAVE_XFREE_XINERAMA, , [Have XFree86-style Xinerama]) + AC_DEFINE(HAVE_XINERAMA,, [Have some version of Xinerama]), + use_xfree_xinerama=no, + [#include ])], + use_xfree_xinerama=no, -lXext $ALL_X_LIBS) + AC_MSG_CHECKING(for Xinerama support on XFree86) + AC_MSG_RESULT($use_xfree_xinerama); + ;; + esac +fi CPPFLAGS="$metacity_save_cppflags"