From: Dmitry V. Levin Date: Tue, 18 Aug 2015 22:53:22 +0000 (+0000) Subject: mips: print _MIPS_SIM in configure.ac for debug purposes X-Git-Tag: v4.11~270 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6684b6857c8155f16bfb4621ea9875fce655ba82;p=strace mips: print _MIPS_SIM in configure.ac for debug purposes * configure.ac [MIPS]: Print _MIPS_SIM. --- diff --git a/configure.ac b/configure.ac index fbd20d21..0819f839 100644 --- a/configure.ac +++ b/configure.ac @@ -150,21 +150,27 @@ AC_MSG_RESULT($arch) AC_SUBST(arch) if test "$arch" = mips; then - AC_CACHE_CHECK([for MIPS ABI], [ac_cv_mips_abi], + AC_CACHE_CHECK([for _MIPS_SIM], [st_cv__MIPS_SIM], + [AC_COMPUTE_INT([st_cv__MIPS_SIM], [_MIPS_SIM], + [#include ], + [AC_MSG_ERROR([_MIPS_SIM cannot be determined])])]) + + AC_CACHE_CHECK([for MIPS ABI], [st_cv_mips_abi], [AC_COMPILE_IFELSE( [AC_LANG_PROGRAM([[#include ]], [[int i[_MIPS_SIM == _MIPS_SIM_ABI32 ? 1 : - 1];]])], - [ac_cv_mips_abi=o32], + [st_cv_mips_abi=o32], [AC_COMPILE_IFELSE( [AC_LANG_PROGRAM([[#include ]], [[int i[_MIPS_SIM == _MIPS_SIM_NABI32 ? 1 : - 1];]])], - [ac_cv_mips_abi=n32], + [st_cv_mips_abi=n32], [AC_COMPILE_IFELSE( [AC_LANG_PROGRAM([[#include ]], [[int i[_MIPS_SIM == _MIPS_SIM_ABI64 ? 1 : - 1];]])], - [ac_cv_mips_abi=n64], - [ac_cv_mips_abi=unknown])])])]) - case "$ac_cv_mips_abi" in + [st_cv_mips_abi=n64], + [st_cv_mips_abi=unknown])])])]) + + case "$st_cv_mips_abi" in o32) AC_DEFINE([LINUX_MIPSO32], [1], [Define for _MIPS_SIM_ABI32.]);; n32) AC_DEFINE([LINUX_MIPSN32], [1], [Define for _MIPS_SIM_NABI32.]);; n64) AC_DEFINE([LINUX_MIPSN64], [1], [Define for _MIPS_SIM_ABI64.]);;