diff options
Diffstat (limited to 'bfd/configure.in')
-rw-r--r-- | bfd/configure.in | 25 |
1 files changed, 18 insertions, 7 deletions
diff --git a/bfd/configure.in b/bfd/configure.in index b3a6e68..1cd8e6a 100644 --- a/bfd/configure.in +++ b/bfd/configure.in @@ -117,13 +117,6 @@ BFD_HOST_LONG_LONG=0 BFD_HOST_64_BIT_DEFINED=0 BFD_HOST_64_BIT= BFD_HOST_U_64_BIT= -if test "x${HOST_64BIT_TYPE}" = "xlong"; then - BFD_HOST_64BIT_LONG=1 -elif test "x${HOST_64BIT_TYPE}" != "x"; then - BFD_HOST_64_BIT_DEFINED=1 - BFD_HOST_64_BIT=${HOST_64BIT_TYPE} - BFD_HOST_U_64_BIT=${HOST_U_64BIT_TYPE} -fi AC_MSG_CHECKING([for long long]) AC_CACHE_VAL(bfd_cv_has_long_long, @@ -133,6 +126,24 @@ bfd_cv_has_long_long=yes, bfd_cv_has_long_long=no)]) AC_MSG_RESULT($bfd_cv_has_long_long) if test $bfd_cv_has_long_long = yes; then BFD_HOST_LONG_LONG=1 + AC_COMPILE_CHECK_SIZEOF(long long) +fi + +AC_COMPILE_CHECK_SIZEOF(long) +if test "x${ac_cv_sizeof_long}" = "x8"; then + host64=true + HOST_64BIT_TYPE="long" +elif test "x${ac_cv_sizeof_long_long}" = "x8"; then + HOST_64BIT_TYPE="long long" + HOST_U_64BIT_TYPE="unsigned long long" +fi + +if test "x${HOST_64BIT_TYPE}" = "xlong"; then + BFD_HOST_64BIT_LONG=1 +elif test "x${HOST_64BIT_TYPE}" != "x"; then + BFD_HOST_64_BIT_DEFINED=1 + BFD_HOST_64_BIT=${HOST_64BIT_TYPE} + BFD_HOST_U_64_BIT=${HOST_U_64BIT_TYPE} fi AC_SUBST(BFD_HOST_64BIT_LONG) |