[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2] Detect x32 ABI in config.guess
From: |
James Clarke |
Subject: |
[PATCH v2] Detect x32 ABI in config.guess |
Date: |
Sat, 24 Feb 2018 00:28:08 +0000 |
---
Changes since v1:
* Use objdump and check for elf32-x86-64 rather than using CC_FOR_BUILD
config.guess | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/config.guess b/config.guess
index 9baaa27..8732f63 100755
--- a/config.guess
+++ b/config.guess
@@ -1046,7 +1046,11 @@ EOF
echo "$UNAME_MACHINE"-dec-linux-"$LIBC"
exit ;;
x86_64:Linux:*:*)
- echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
+ if objdump -f /bin/sh | grep -q elf32-x86-64; then
+ echo "$UNAME_MACHINE"-pc-linux-"$LIBC"x32
+ else
+ echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
+ fi
exit ;;
xtensa*:Linux:*:*)
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
--
2.16.2