From cccc5a26272570b4b18b3a04236c0742d1cbc471 Mon Sep 17 00:00:00 2001 From: Peter Korsgaard Date: Sun, 29 Mar 2009 19:10:30 +0000 Subject: libX11: fix build on hosts without libx11-dev Make sure the build doesn't use keysymdef.h from the host. --- .../xlib_libX11/xlib_libX11-1.1.5-keysymdef.patch | 40 ++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 package/x11r7/xlib_libX11/xlib_libX11-1.1.5-keysymdef.patch (limited to 'package/x11r7/xlib_libX11/xlib_libX11-1.1.5-keysymdef.patch') diff --git a/package/x11r7/xlib_libX11/xlib_libX11-1.1.5-keysymdef.patch b/package/x11r7/xlib_libX11/xlib_libX11-1.1.5-keysymdef.patch new file mode 100644 index 000000000..1ac9f9d80 --- /dev/null +++ b/package/x11r7/xlib_libX11/xlib_libX11-1.1.5-keysymdef.patch @@ -0,0 +1,40 @@ +[patch]: configure: add --with-keysymdef argument for cross compilation + +Based on a similar patch from Openembedded. + +The libX11 configure script hardcodes the location to keysymdef.h as +/include/X11/keysymdef.h, which is fine for native compilation, +but breaks with cross compilation as that directory is a location on +the target, not the build host. + +Fix it by providing an explicit --with-keysymdef=. + +Signed-off-by: Peter Korsgaard Index: libX11-1.1.5/configure.ac +=================================================================== +--- libX11-1.1.5.orig/configure.ac 2008-10-28 11:36:49.000000000 +0000 ++++ libX11-1.1.5/configure.ac 2008-10-28 11:40:05.000000000 +0000 +@@ -221,13 +221,21 @@ + # Find keysymdef.h + # + AC_MSG_CHECKING([keysymdef.h]) +-dir=`pkg-config --variable=includedir xproto` +-KEYSYMDEF="$dir/X11/keysymdef.h" ++AC_ARG_WITH(keysymdef, ++ AC_HELP_STRING([--with-keysymdef=DIR/keysymdef.h], [The location of keysymdef.h]), ++ KEYSYMDEF=$withval, KEYSYMDEF="") ++ ++if test x$KEYSYMDEF = x; then ++ dir=`pkg-config --variable=includedir xproto` ++ KEYSYMDEF="$dir/X11/keysymdef.h" ++fi ++ + if test -f "$KEYSYMDEF"; then +- AC_MSG_RESULT([$KEYSYMDEF]) ++ AC_MSG_RESULT([$KEYSYMDEF]) + else + AC_MSG_ERROR([Cannot find keysymdef.h]) + fi ++ + AC_SUBST(KEYSYMDEF) + + AM_CONDITIONAL(UDC, test xfalse = xtrue) -- cgit v1.2.3