This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Please update config.guess for Linux/mips.
- From: "H . J . Lu" <hjl at lucon dot org>
- To: binutils at sourceware dot cygnus dot com
- Cc: gcc at gcc dot gnu dot org, config-patches at gnu dot org
- Date: Mon, 17 Dec 2001 18:12:40 -0800
- Subject: Please update config.guess for Linux/mips.
This patch is necessary for the native build on new Linux/mips. I
think it has been checked into config CVS. However, I can no longer
access config CVS:
/cvs/config: no such repository
cvs update: authorization failed: server anoncvs.gnu.org rejected access to /cvs/config for user anoncvs
cvs update: used empty password; try "cvs login" with a real password
Could someone please check it out?
Thanks.
H.J.
-----
2001-12-06 H.J. Lu (hjl@gnu.org)
* config.guess: Properly handle Linux/mips.
--- config.guess.mips Mon Nov 5 08:09:32 2001
+++ config.guess Thu Dec 6 10:31:40 2001
@@ -767,10 +767,21 @@ EOF
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit 0 ;;
mips:Linux:*:*)
- case `sed -n '/^byte/s/^.*: \(.*\) endian/\1/p' < /proc/cpuinfo` in
- big) echo mips-unknown-linux-gnu && exit 0 ;;
- little) echo mipsel-unknown-linux-gnu && exit 0 ;;
- esac
+ eval $set_cc_for_build
+ cat >$dummy.c <<EOF
+#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
+cpu=mipsel
+#endif
+#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
+cpu=mips
+#endif
+EOF
+ cpu=
+ eval `$CC_FOR_BUILD -E $dummy.c | grep cpu=`;
+ rm -f $dummy.c
+ if test -n "$cpu"; then
+ echo $cpu-unknown-linux-gnu && exit 0
+ fi
;;
ppc:Linux:*:*)
echo powerpc-unknown-linux-gnu