summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorMarc Dietrich <marvin24@gmx.de>2009-08-31 08:56:33 -0700
committerBrian Paul <brianp@vmware.com>2009-08-31 11:22:36 -0600
commitc705e7238292d6c534d18dddcc03ecc6a24a5d66 (patch)
treeb1f356a541ff5e1e92c870e8feb6edb47e37febe /configure.ac
parentf315c0128b5f6317f910f6c54119fea97256254c (diff)
mesa: fix 32bit cross compilation on a 64bit machine
When cross compiling on a 64bit machine, gen_matypes.c is build for the host machine (64bit) but must generates code for the target machine (32bit). This causes wrong offsets all over the place and crashes googleearth on my machine. Solution is to add -m32 when cross compiling. Attached patch is compatible with linux-x86-32 and autoconf based builds.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac1
1 files changed, 1 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 9d318b3fc2..c5ef676e2e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -126,6 +126,7 @@ AC_ARG_ENABLE([32-bit],
if test "x$enable_32bit" = xyes; then
if test "x$GCC" = xyes; then
CFLAGS="$CFLAGS -m32"
+ ARCH_FLAGS="$ARCH_FLAGS -m32"
fi
if test "x$GXX" = xyes; then
CXXFLAGS="$CXXFLAGS -m32"