diff -Naur libX11-1.2.1-old/configure.ac libX11-1.2.1-new/configure.ac --- libX11-1.2.1-old/configure.ac 2009-04-07 15:18:30.000000000 -0700 +++ libX11-1.2.1-new/configure.ac 2009-07-01 09:35:08.000000000 -0700 @@ -7,6 +7,9 @@ [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], libX11) AC_CONFIG_SRCDIR([Makefile.am]) +AC_CANONICAL_BUILD +AC_CANONICAL_HOST + AM_INIT_AUTOMAKE([dist-bzip2 foreign]) AM_MAINTAINER_MODE @@ -23,6 +26,8 @@ DOLT AC_PROG_CC XORG_CWARNFLAGS +PKG_PROG_PKG_CONFIG +m4_pattern_allow([^PKG_CONFIG_SYSROOT_DIR$]) if test x"$CC_FOR_BUILD" = x; then if test x"$cross_compiling" = xyes; then @@ -33,6 +38,27 @@ fi AC_SUBST([CC_FOR_BUILD]) +if test x"$CPPFLAGS_FOR_BUILD" = x; then + if test ! x"$cross_compiling" = xyes; then + CPPFLAGS_FOR_BUILD=${CPPFLAGS} + fi +fi +AC_SUBST(CPPFLAGS_FOR_BUILD) + +if test x"$CFLAGS_FOR_BUILD" = x; then + if test ! x"$cross_compiling" = xyes; then + CFLAGS_FOR_BUILD=${CFLAGS} + fi +fi +AC_SUBST(CFLAGS_FOR_BUILD) + +if test x"$LDFLAGS_FOR_BUILD" = x; then + if test ! x"$cross_compiling" = xyes; then + LDFLAGS_FOR_BUILD=${LDFLAGS} + fi +fi +AC_SUBST(LDFLAGS_FOR_BUILD) + XORG_PROG_RAWCPP # Build with XCB support? @@ -257,7 +283,7 @@ # Find keysymdef.h # AC_MSG_CHECKING([keysymdef.h]) -dir=`pkg-config --variable=includedir xproto` +dir=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=includedir xproto` KEYSYMDEF="$dir/X11/keysymdef.h" if test -f "$KEYSYMDEF"; then AC_MSG_RESULT([$KEYSYMDEF]) diff -Naur libX11-1.2.1-old/src/util/Makefile.am libX11-1.2.1-new/src/util/Makefile.am --- libX11-1.2.1-old/src/util/Makefile.am 2008-10-07 10:18:19.000000000 -0700 +++ libX11-1.2.1-new/src/util/Makefile.am 2009-07-01 09:19:00.000000000 -0700 @@ -5,6 +5,9 @@ makekeys_CFLAGS=$(X11_CFLAGS) CC = @CC_FOR_BUILD@ +CPPFLAGS = @CPPFLAGS_FOR_BUILD@ +CFLAGS = @CFLAGS_FOR_BUILD@ +LDFLAGS = @LDFLAGS_FOR_BUILD@ EXTRA_DIST = mkks.sh