aboutsummaryrefslogtreecommitdiff
path: root/bfd/configure.in
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2004-03-16 09:05:22 +0000
committerAlan Modra <amodra@gmail.com>2004-03-16 09:05:22 +0000
commitccba357f634fbfc05dab5129a75eb5b7bc2b0c42 (patch)
treeda79a48e232b9d64c31c7245abf97867f9af80cb /bfd/configure.in
parent419783084d0c052f6111401342f791031564ebe4 (diff)
downloadgdb-ccba357f634fbfc05dab5129a75eb5b7bc2b0c42.zip
gdb-ccba357f634fbfc05dab5129a75eb5b7bc2b0c42.tar.gz
gdb-ccba357f634fbfc05dab5129a75eb5b7bc2b0c42.tar.bz2
* configure.in (HOST_64BIT_TYPE, HOST_U_64BIT_TYPE): Don't override
values selected in configure.host. Require both to be defined before setting BFD_HOST_64_BIT_DEFINED. Protect assignment to corresponding BFD_HOST vars with quotes. <${host64}-${target64}-${want64} in *true*>: Don't exempt gcc; Always require BFD_HOST_64_BIT_DEFINED. <file_ptr type>: Find off_t size before emitting message. Combine off_t and ftello64 conditional. * configure: Regenerate.
Diffstat (limited to 'bfd/configure.in')
-rw-r--r--bfd/configure.in33
1 files changed, 14 insertions, 19 deletions
diff --git a/bfd/configure.in b/bfd/configure.in
index 851be41..e08a663 100644
--- a/bfd/configure.in
+++ b/bfd/configure.in
@@ -132,20 +132,18 @@ fi
AC_COMPILE_CHECK_SIZEOF(long)
if test "x${ac_cv_sizeof_long}" = "x8"; then
host64=true
- HOST_64BIT_TYPE="long"
- HOST_U_64BIT_TYPE="unsigned long"
+ BFD_HOST_64BIT_LONG=1
+ test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
+ test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
elif test "x${ac_cv_sizeof_long_long}" = "x8"; then
- HOST_64BIT_TYPE="long long"
- HOST_U_64BIT_TYPE="unsigned long long"
+ test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
+ test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
fi
-if test "x${HOST_64BIT_TYPE}" = "xlong"; then
- BFD_HOST_64BIT_LONG=1
-fi
-if test "x${HOST_64BIT_TYPE}" != "x"; then
+if test -n "${HOST_64BIT_TYPE}" -a -n "${HOST_U_64BIT_TYPE}"; then
BFD_HOST_64_BIT_DEFINED=1
- BFD_HOST_64_BIT=${HOST_64BIT_TYPE}
- BFD_HOST_U_64_BIT=${HOST_U_64BIT_TYPE}
+ BFD_HOST_64_BIT="${HOST_64BIT_TYPE}"
+ BFD_HOST_U_64_BIT="${HOST_U_64BIT_TYPE}"
fi
AC_SUBST(BFD_HOST_64BIT_LONG)
@@ -890,7 +888,7 @@ case ${host64}-${target64}-${want64} in
wordsize=64
bfd_libs='$(BFD64_LIBS) $(BFD32_LIBS)'
all_backends='$(BFD64_BACKENDS) $(BFD32_BACKENDS)'
- if test -z "$GCC" && test "$BFD_HOST_64BIT_LONG" = "0" && test "$BFD_HOST_64_BIT_DEFINED" = "0"; then
+ if test $BFD_HOST_64_BIT_DEFINED = 0; then
AC_MSG_WARN([You have requested a 64 bit BFD configuration, but])
AC_MSG_WARN([your compiler may not have a 64 bit integral type])
fi
@@ -927,17 +925,14 @@ AC_SUBST(bfd_default_target_size)
# Hopefully a reasonable assumption since fseeko et.al. should be
# upward compatible.
AC_CHECK_FUNCS(ftello ftello64 fseeko fseeko64)
-AC_MSG_CHECKING([file_ptr type])
-bfd_file_ptr="long"
-bfd_ufile_ptr="unsigned long"
if test x"$ac_cv_func_ftello" = xyes -a x"$ac_cv_func_fseeko" = xyes; then
AC_COMPILE_CHECK_SIZEOF(off_t)
- if test "x${ac_cv_sizeof_off_t}" = "x8"; then
- bfd_file_ptr=BFD_HOST_64_BIT
- bfd_ufile_ptr=BFD_HOST_U_64_BIT
- fi
fi
-if test x"$ac_cv_func_ftello64" = xyes -a x"$ac_cv_func_fseeko64" = xyes; then
+AC_MSG_CHECKING([file_ptr type])
+bfd_file_ptr="long"
+bfd_ufile_ptr="unsigned long"
+if test x"$ac_cv_func_ftello64" = xyes -a x"$ac_cv_func_fseeko64" = xyes \
+ -o x"${ac_cv_sizeof_off_t}" = x8; then
bfd_file_ptr=BFD_HOST_64_BIT
bfd_ufile_ptr=BFD_HOST_U_64_BIT
fi