Author: qboosh Date: Sat Feb 18 16:08:26 2006 GMT Module: SOURCES Tag: HEAD ---- Log message: - fix libX11 detection without xmkmf and libXt (based on changes from CVS and Fedora patch)
---- Files affected: SOURCES: autoconf-x.patch (NONE -> 1.1) (NEW) ---- Diffs: ================================================================ Index: SOURCES/autoconf-x.patch diff -u /dev/null SOURCES/autoconf-x.patch:1.1 --- /dev/null Sat Feb 18 17:08:26 2006 +++ SOURCES/autoconf-x.patch Sat Feb 18 17:08:21 2006 @@ -0,0 +1,69 @@ +--- autoconf-2.59/lib/autoconf/libs.m4.orig 2003-05-22 14:05:13.000000000 +0200 ++++ autoconf-2.59/lib/autoconf/libs.m4 2006-02-18 16:45:40.815890250 +0100 +@@ -180,7 +180,8 @@ + # Internal subroutine of _AC_PATH_X. + # Set ac_x_includes and/or ac_x_libraries. + m4_define([_AC_PATH_X_XMKMF], +-[rm -fr conftest.dir ++[AC_ARG_VAR(XMKMF, [Path to xmkmf, Makefile generator for X Window System])dnl ++rm -f -r conftest.dir + if mkdir conftest.dir; then + cd conftest.dir + # Make sure to not put "make" in the Imakefile rules, since we grep it out. +@@ -188,7 +189,7 @@ + acfindx: + @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"' + _ACEOF +- if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then ++ if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then + # GNU make sometimes prints "make[1]: Entering...", which would confuse us. + eval `${MAKE-make} acfindx 2>/dev/null | grep -v make` + # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. +@@ -202,7 +203,7 @@ + # bogus both because they are the default anyway, and because + # using them would break gcc on systems where it needs fixed includes. + case $ac_im_incroot in +- /usr/include) ;; ++ /usr/include) ac_x_includes= ;; + *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; + esac + case $ac_im_usrlibdir in +@@ -259,13 +260,13 @@ + /usr/openwin/share/include' + + if test "$ac_x_includes" = no; then +- # Guess where to find include files, by looking for Intrinsic.h. ++ # Guess where to find include files, by looking for Xlib.h. + # First, try using that file with no special directory specified. +- AC_PREPROC_IFELSE([AC_LANG_SOURCE([EMAIL PROTECTED]:@include <X11/Intrinsic.h>])], ++ AC_PREPROC_IFELSE([AC_LANG_SOURCE([EMAIL PROTECTED]:@include <X11/Xlib.h>])], + [# We can compile using X headers with no special include directory. + ac_x_includes=], + [for ac_dir in $ac_x_header_dirs; do +- if test -r "$ac_dir/X11/Intrinsic.h"; then ++ if test -r "$ac_dir/X11/Xlib.h"; then + ac_x_includes=$ac_dir + break + fi +@@ -277,9 +278,9 @@ + # See if we find them without any special options. + # Don't add to $LIBS permanently. + ac_save_LIBS=$LIBS +- LIBS="-lXt $LIBS" +- AC_LINK_IFELSE([AC_LANG_PROGRAM([EMAIL PROTECTED]:@include <X11/Intrinsic.h>], +- [XtMalloc (0)])], ++ LIBS="-lX11 $LIBS" ++ AC_LINK_IFELSE([AC_LANG_PROGRAM([EMAIL PROTECTED]:@include <X11/Xlib.h>], ++ [XrmInitialize ()])], + [LIBS=$ac_save_LIBS + # We can link X programs with no special library path. + ac_x_libraries=], +@@ -288,7 +289,7 @@ + do + # Don't even attempt the hair of trying to link an X program! + for ac_extension in a so sl; do +- if test -r $ac_dir/libXt.$ac_extension; then ++ if test -r $ac_dir/libX11.$ac_extension; then + ac_x_libraries=$ac_dir + break 2 + fi ================================================================ _______________________________________________ pld-cvs-commit mailing list pld-cvs-commit@lists.pld-linux.org http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit