From: Alan Modra Date: Mon, 3 Jul 2017 12:25:57 +0000 (+0930) Subject: Missing config for bfd.c:_doprnt X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=33c734b2f860f77badb1e25d16e144e9db77d1bf;p=binutils-gdb.git Missing config for bfd.c:_doprnt This function uses HAVE_LONG_LONG and HAVE_LONG_DOUBLE * configure.ac: Invoke AC_CHECK_TYPES for long long. Invoke AC_TYPE_LONG_DOUBLE. * configure: Regenerate. * config.in: Regenerate. --- diff --git a/bfd/ChangeLog b/bfd/ChangeLog index c384a0f028b..271cc1caa40 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,10 @@ +2017-07-03 Alan Modra + + * configure.ac: Invoke AC_CHECK_TYPES for long long. Invoke + AC_TYPE_LONG_DOUBLE. + * configure: Regenerate. + * config.in: Regenerate. + 2017-06-29 Andrew Waterman * elfnn-riscv.c (riscv_elf_adjust_dynamic_symbol): Fix TLS copy diff --git a/bfd/config.in b/bfd/config.in index 2d5a381fb3e..75a5ff015ed 100644 --- a/bfd/config.in +++ b/bfd/config.in @@ -133,6 +133,12 @@ /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H +/* Define to 1 if the system has the type `long double'. */ +#undef HAVE_LONG_DOUBLE + +/* Define to 1 if the system has the type `long long'. */ +#undef HAVE_LONG_LONG + /* Define if has lwpstatus_t. */ #undef HAVE_LWPSTATUS_T diff --git a/bfd/configure b/bfd/configure index 24e3e2f6790..ed20825009d 100755 --- a/bfd/configure +++ b/bfd/configure @@ -1908,6 +1908,60 @@ $as_echo "$ac_res" >&6; } } # ac_fn_c_check_func +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + +} # ac_fn_c_check_type + # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES # -------------------------------------------- # Tries to find the compile-time value of EXPR in a program that includes @@ -2086,60 +2140,6 @@ rm -f conftest.val } # ac_fn_c_compute_int -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=no" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof ($2)) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof (($2))) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - eval "$3=yes" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - -} # ac_fn_c_check_type - # ac_fn_c_check_decl LINENO SYMBOL VAR # ------------------------------------ # Tests whether SYMBOL is declared, setting cache variable VAR accordingly. @@ -12888,6 +12888,54 @@ BFD_HOST_64_BIT= BFD_HOST_U_64_BIT= BFD_HOSTPTR_T="unsigned long" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double" >&5 +$as_echo_n "checking for long double... " >&6; } +if test "${ac_cv_type_long_double+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$GCC" = yes; then + ac_cv_type_long_double=yes + else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* The Stardent Vistra knows sizeof (long double), but does + not support it. */ + long double foo = 0.0L; +int +main () +{ +static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8. */ + sizeof (double) <= sizeof (long double))]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_type_long_double=yes +else + ac_cv_type_long_double=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5 +$as_echo "$ac_cv_type_long_double" >&6; } + if test $ac_cv_type_long_double = yes; then + +$as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h + + fi + +ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default" +if test "x$ac_cv_type_long_long" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_LONG_LONG 1 +_ACEOF + # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. @@ -12922,6 +12970,8 @@ cat >>confdefs.h <<_ACEOF _ACEOF +fi + # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. diff --git a/bfd/configure.ac b/bfd/configure.ac index e568847e464..dfbe3dfca49 100644 --- a/bfd/configure.ac +++ b/bfd/configure.ac @@ -160,7 +160,8 @@ BFD_HOST_64_BIT= BFD_HOST_U_64_BIT= BFD_HOSTPTR_T="unsigned long" -AC_CHECK_SIZEOF(long long) +AC_TYPE_LONG_DOUBLE +AC_CHECK_TYPES([long long], [AC_CHECK_SIZEOF(long long)]) AC_CHECK_SIZEOF(void *) AC_CHECK_SIZEOF(long)