From 0a0b37fe0fd1e0152766e3924fdea00427420e39 Mon Sep 17 00:00:00 2001 From: Pino Toscano Date: Tue, 25 May 2010 10:46:39 +0200 Subject: Fix architecture detection on GNU/Hurd. On GNU/Hurd, `uname -m` returns a string like "i686-AT386", which is not recognized. Instead, do a specific mangling on "GNU" host, the same done by autotools' config.guess, so the architecture can be identified and the proper atomic primitives used. Merge-request: 638 Reviewed-by: Oswald Buddenhagen --- configure | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/configure b/configure index f2023b8..0111f51 100755 --- a/configure +++ b/configure @@ -2755,6 +2755,17 @@ fi if [ -z "${CFG_HOST_ARCH}" ]; then case "$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_MACHINE" in + GNU:*:*) + CFG_HOST_ARCH=`echo ${UNAME_MACHINE} | sed -e 's,[-/].*$,,'` + case "$CFG_HOST_ARCH" in + i?86) + CFG_HOST_ARCH=i386 + ;; + esac + if [ "$OPT_VERBOSE" = "yes" ]; then + echo " GNU/Hurd ($CFG_HOST_ARCH)" + fi + ;; IRIX*:*:*) CFG_HOST_ARCH=`uname -p` if [ "$OPT_VERBOSE" = "yes" ]; then -- cgit v0.12