3 abiflag=`$CC $CFLAGS $CPPFLAGS -E -dM -xc /dev/null | sed -n 's/^#define _MIPS_SIM \(.*\)/\1/p'`
4 mips16flag=`$CC $CFLAGS $CPPFLAGS -E -dM -xc /dev/null | sed -n 's/^#define __mips16 \(.*\)/\1/p'`
7 if test "$abiflag" = "_ABIO32" ; then
8 if test "$mips16flag" = "1" ; then
9 machine=mips/mips32/mips16
13 elif test "$abiflag" = "_ABIN32" ; then
14 machine=mips/mips64/n32
15 elif test "$abiflag" = "_ABI64" ; then
16 machine=mips/mips64/n64
18 as_fn_error $? "Unable to determine ABI." "$LINENO" 5
20 # $config_machine is not really needed here but the slash after
21 # $machine is needed by the case statement in
22 # sysdeps/unix/sysv/linux/mips/configure.ac.
23 machine=$machine/$config_machine
25 if test "$abiflag" != "_ABIO32" -a "$mips16flag" = "1"; then
26 as_fn_error $? "MIPS16 is only supported with the o32 ABI." "$LINENO" 5