@@ -50,7 +50,7 @@ export sysdep_dir := $(sysdep_dir)
include $(common-objpfx)config.make
# What flags to give to sources which call user provided callbacks
-uses-callbacks = $(exceptions)
+uses-callbacks = -fexceptions
# What flags to give to tests which test stack alignment
stack-align-test-flags =
@@ -70,7 +70,6 @@ use-default-link = @use_default_link@
output-format = @libc_cv_output_format@
have-cxx-thread_local = @libc_cv_cxx_thread_local@
-exceptions = @exceptions@
multi-arch = @multi_arch@
mach-interface-list = @mach_interface_list@
@@ -624,7 +624,6 @@ LIBGD
libc_cv_cc_loop_to_function
libc_cv_cc_submachine
libc_cv_cc_nofma
-exceptions
gnu89_inline
libc_cv_ssp
fno_unit_at_a_time
@@ -6471,36 +6470,6 @@ if test $libc_cv_ld_no_whole_archive = no; then
as_fn_error $? "support for --no-whole-archive is needed" "$LINENO" 5
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc -fexceptions" >&5
-$as_echo_n "checking for gcc -fexceptions... " >&6; }
-if ${libc_cv_gcc_exceptions+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat > conftest.c <<\EOF
-_start () {}
-int __eh_pc;
-__throw () {}
-EOF
-if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
- -nostdlib -nostartfiles -fexceptions
- -o conftest conftest.c 1>&5'
- { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- libc_cv_gcc_exceptions=yes
-else
- libc_cv_gcc_exceptions=no
-fi
-rm -f conftest*
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_gcc_exceptions" >&5
-$as_echo "$libc_cv_gcc_exceptions" >&6; }
-if test $libc_cv_gcc_exceptions = yes; then
- exceptions=-fexceptions
-fi
-
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_memset" >&5
$as_echo_n "checking for __builtin_memset... " >&6; }
if ${libc_cv_gcc_builtin_memset+:} false; then :
@@ -1629,26 +1629,6 @@ if test $libc_cv_ld_no_whole_archive = no; then
AC_MSG_ERROR([support for --no-whole-archive is needed])
fi
-AC_CACHE_CHECK(for gcc -fexceptions, libc_cv_gcc_exceptions, [dnl
-cat > conftest.c <<\EOF
-_start () {}
-int __eh_pc;
-__throw () {}
-EOF
-dnl No \ in command here because it ends up inside ''.
-if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
- -nostdlib -nostartfiles -fexceptions
- -o conftest conftest.c 1>&AS_MESSAGE_LOG_FD]); then
- libc_cv_gcc_exceptions=yes
-else
- libc_cv_gcc_exceptions=no
-fi
-rm -f conftest*])
-if test $libc_cv_gcc_exceptions = yes; then
- exceptions=-fexceptions
-fi
-AC_SUBST(exceptions)dnl
-
AC_CACHE_CHECK(for __builtin_memset, libc_cv_gcc_builtin_memset, [dnl
cat > conftest.c <<\EOF
void zero (void *x)
@@ -60,25 +60,25 @@ CFLAGS-vsnprintf_chk.c = $(libio-mtsafe)
CFLAGS-asprintf_chk.c = $(libio-mtsafe)
CFLAGS-vasprintf_chk.c = $(libio-mtsafe)
CFLAGS-obprintf_chk.c = $(libio-mtsafe)
-CFLAGS-dprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-vdprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-printf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-fprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-vprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-vfprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-gets_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-fgets_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-fgets_u_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-fread_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-fread_u_chk.c = $(libio-mtsafe) $(exceptions)
+CFLAGS-dprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-vdprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-printf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-fprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-vprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-vfprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-gets_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-fgets_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-fgets_u_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-fread_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-fread_u_chk.c = $(libio-mtsafe) -fexceptions
CFLAGS-swprintf_chk.c = $(libio-mtsafe)
CFLAGS-vswprintf_chk.c = $(libio-mtsafe)
-CFLAGS-wprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-fwprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-vwprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-vfwprintf_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-fgetws_chk.c = $(libio-mtsafe) $(exceptions)
-CFLAGS-fgetws_u_chk.c = $(libio-mtsafe) $(exceptions)
+CFLAGS-wprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-fwprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-vwprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-vfwprintf_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-fgetws_chk.c = $(libio-mtsafe) -fexceptions
+CFLAGS-fgetws_u_chk.c = $(libio-mtsafe) -fexceptions
CFLAGS-read_chk.c = -fexceptions -fasynchronous-unwind-tables
CFLAGS-pread_chk.c = -fexceptions -fasynchronous-unwind-tables
CFLAGS-pread64_chk.c = -fexceptions -fasynchronous-unwind-tables
@@ -84,64 +84,64 @@ endif
CPPFLAGS += $(libio-mtsafe)
# Support for exception handling.
-CFLAGS-fileops.c = $(exceptions)
-CFLAGS-fputc.c = $(exceptions)
-CFLAGS-fputwc.c = $(exceptions)
-CFLAGS-freopen64.c = $(exceptions)
-CFLAGS-freopen.c = $(exceptions)
-CFLAGS-fseek.c = $(exceptions)
-CFLAGS-fseeko64.c = $(exceptions)
-CFLAGS-fseeko.c = $(exceptions)
-CFLAGS-ftello64.c = $(exceptions)
-CFLAGS-ftello.c = $(exceptions)
-CFLAGS-fwide.c = $(exceptions)
-CFLAGS-genops.c = $(exceptions)
-CFLAGS-getc.c = $(exceptions)
-CFLAGS-getchar.c = $(exceptions)
-CFLAGS-getwc.c = $(exceptions)
-CFLAGS-getwchar.c = $(exceptions)
-CFLAGS-iofclose.c = $(exceptions)
-CFLAGS-iofflush.c = $(exceptions)
-CFLAGS-iofgetpos64.c = $(exceptions)
-CFLAGS-iofgetpos.c = $(exceptions)
-CFLAGS-iofgets.c = $(exceptions)
-CFLAGS-iofgetws.c = $(exceptions)
-CFLAGS-iofputs.c = $(exceptions)
-CFLAGS-iofputws.c = $(exceptions)
-CFLAGS-iofread.c = $(exceptions)
-CFLAGS-iofsetpos64.c = $(exceptions)
-CFLAGS-iofsetpos.c = $(exceptions)
-CFLAGS-ioftell.c = $(exceptions)
-CFLAGS-iofwrite.c = $(exceptions)
-CFLAGS-iogetdelim.c = $(exceptions)
-CFLAGS-iogetline.c = $(exceptions)
-CFLAGS-iogets.c = $(exceptions)
-CFLAGS-iogetwline.c = $(exceptions)
-CFLAGS-ioputs.c = $(exceptions)
-CFLAGS-ioseekoff.c = $(exceptions)
-CFLAGS-ioseekpos.c = $(exceptions)
-CFLAGS-iosetbuffer.c = $(exceptions)
-CFLAGS-iosetvbuf.c = $(exceptions)
-CFLAGS-ioungetc.c = $(exceptions)
-CFLAGS-ioungetwc.c = $(exceptions)
-CFLAGS-oldfileops.c = $(exceptions)
-CFLAGS-oldiofclose.c = $(exceptions)
-CFLAGS-oldiofgetpos64.c = $(exceptions)
-CFLAGS-oldiofgetpos.c = $(exceptions)
-CFLAGS-oldiofsetpos64.c = $(exceptions)
-CFLAGS-oldiofsetpos.c = $(exceptions)
-CFLAGS-peekc.c = $(exceptions)
-CFLAGS-putc.c = $(exceptions)
-CFLAGS-putchar.c = $(exceptions)
-CFLAGS-putwc.c = $(exceptions)
-CFLAGS-putwchar.c = $(exceptions)
-CFLAGS-rewind.c = $(exceptions)
-CFLAGS-wfileops.c = $(exceptions)
-CFLAGS-wgenops.c = $(exceptions)
-CFLAGS-oldiofopen.c = $(exceptions)
-CFLAGS-iofopen.c = $(exceptions)
-CFLAGS-iofopen64.c = $(exceptions)
-CFLAGS-oldtmpfile.c = $(exceptions)
+CFLAGS-fileops.c = -fexceptions
+CFLAGS-fputc.c = -fexceptions
+CFLAGS-fputwc.c = -fexceptions
+CFLAGS-freopen64.c = -fexceptions
+CFLAGS-freopen.c = -fexceptions
+CFLAGS-fseek.c = -fexceptions
+CFLAGS-fseeko64.c = -fexceptions
+CFLAGS-fseeko.c = -fexceptions
+CFLAGS-ftello64.c = -fexceptions
+CFLAGS-ftello.c = -fexceptions
+CFLAGS-fwide.c = -fexceptions
+CFLAGS-genops.c = -fexceptions
+CFLAGS-getc.c = -fexceptions
+CFLAGS-getchar.c = -fexceptions
+CFLAGS-getwc.c = -fexceptions
+CFLAGS-getwchar.c = -fexceptions
+CFLAGS-iofclose.c = -fexceptions
+CFLAGS-iofflush.c = -fexceptions
+CFLAGS-iofgetpos64.c = -fexceptions
+CFLAGS-iofgetpos.c = -fexceptions
+CFLAGS-iofgets.c = -fexceptions
+CFLAGS-iofgetws.c = -fexceptions
+CFLAGS-iofputs.c = -fexceptions
+CFLAGS-iofputws.c = -fexceptions
+CFLAGS-iofread.c = -fexceptions
+CFLAGS-iofsetpos64.c = -fexceptions
+CFLAGS-iofsetpos.c = -fexceptions
+CFLAGS-ioftell.c = -fexceptions
+CFLAGS-iofwrite.c = -fexceptions
+CFLAGS-iogetdelim.c = -fexceptions
+CFLAGS-iogetline.c = -fexceptions
+CFLAGS-iogets.c = -fexceptions
+CFLAGS-iogetwline.c = -fexceptions
+CFLAGS-ioputs.c = -fexceptions
+CFLAGS-ioseekoff.c = -fexceptions
+CFLAGS-ioseekpos.c = -fexceptions
+CFLAGS-iosetbuffer.c = -fexceptions
+CFLAGS-iosetvbuf.c = -fexceptions
+CFLAGS-ioungetc.c = -fexceptions
+CFLAGS-ioungetwc.c = -fexceptions
+CFLAGS-oldfileops.c = -fexceptions
+CFLAGS-oldiofclose.c = -fexceptions
+CFLAGS-oldiofgetpos64.c = -fexceptions
+CFLAGS-oldiofgetpos.c = -fexceptions
+CFLAGS-oldiofsetpos64.c = -fexceptions
+CFLAGS-oldiofsetpos.c = -fexceptions
+CFLAGS-peekc.c = -fexceptions
+CFLAGS-putc.c = -fexceptions
+CFLAGS-putchar.c = -fexceptions
+CFLAGS-putwc.c = -fexceptions
+CFLAGS-putwchar.c = -fexceptions
+CFLAGS-rewind.c = -fexceptions
+CFLAGS-wfileops.c = -fexceptions
+CFLAGS-wgenops.c = -fexceptions
+CFLAGS-oldiofopen.c = -fexceptions
+CFLAGS-iofopen.c = -fexceptions
+CFLAGS-iofopen64.c = -fexceptions
+CFLAGS-oldtmpfile.c = -fexceptions
# XXX Do we need filedoalloc and wfiledoalloc? Others?
CFLAGS-tst_putwc.c = -DOBJPFX=\"$(objpfx)\"
@@ -114,18 +114,18 @@ CFLAGS-psignal.c = -fexceptions
CFLAGS-vprintf.c = -fexceptions
CFLAGS-cuserid.c = -fexceptions
-CFLAGS-vfprintf.c += $(exceptions)
-CFLAGS-fprintf.c += $(exceptions)
-CFLAGS-printf.c += $(exceptions)
-CFLAGS-vfwprintf.c += $(exceptions)
-CFLAGS-vfscanf.c += $(exceptions)
-CFLAGS-vfwscanf.c += $(exceptions)
-CFLAGS-fscanf.c += $(exceptions)
-CFLAGS-scanf.c += $(exceptions)
-CFLAGS-isoc99_vfscanf.c += $(exceptions)
-CFLAGS-isoc99_vscanf.c += $(exceptions)
-CFLAGS-isoc99_fscanf.c += $(exceptions)
-CFLAGS-isoc99_scanf.c += $(exceptions)
+CFLAGS-vfprintf.c += -fexceptions
+CFLAGS-fprintf.c += -fexceptions
+CFLAGS-printf.c += -fexceptions
+CFLAGS-vfwprintf.c += -fexceptions
+CFLAGS-vfscanf.c += -fexceptions
+CFLAGS-vfwscanf.c += -fexceptions
+CFLAGS-fscanf.c += -fexceptions
+CFLAGS-scanf.c += -fexceptions
+CFLAGS-isoc99_vfscanf.c += -fexceptions
+CFLAGS-isoc99_vscanf.c += -fexceptions
+CFLAGS-isoc99_fscanf.c += -fexceptions
+CFLAGS-isoc99_scanf.c += -fexceptions
CFLAGS-errlist.c = $(fno-unit-at-a-time)
CFLAGS-siglist.c = $(fno-unit-at-a-time)
@@ -313,6 +313,3 @@ libc_cv_gcc_unwind_find_fde=no
# Remove -fno-unwind-tables that was added in sysdeps/arm/preconfigure.ac.
CFLAGS=${CFLAGS% -fno-unwind-tables}
-
-libc_cv_gcc_exceptions=yes
-exceptions=-fexceptions
@@ -123,9 +123,3 @@ libc_cv_gcc_unwind_find_fde=no
# Remove -fno-unwind-tables that was added in sysdeps/arm/preconfigure.ac.
CFLAGS=${CFLAGS% -fno-unwind-tables}
-
-dnl The normal configure check for gcc -fexecptions fails because it can't
-dnl find __aeabi_unwind_cpp_pr0. Work around this here; our GCC definitely
-dnl has -fexceptions.
-libc_cv_gcc_exceptions=yes
-exceptions=-fexceptions
@@ -84,10 +84,10 @@ CFLAGS-wcstold_l.c = $(strtox-CFLAGS)
CFLAGS-wcstof_l.c = $(strtox-CFLAGS)
CPPFLAGS-tst-wchar-h.c = -D_FORTIFY_SOURCE=2
-CFLAGS-isoc99_wscanf.c += $(exceptions)
-CFLAGS-isoc99_fwscanf.c += $(exceptions)
-CFLAGS-isoc99_vwscanf.c += $(exceptions)
-CFLAGS-isoc99_vfwscanf.c += $(exceptions)
+CFLAGS-isoc99_wscanf.c += -fexceptions
+CFLAGS-isoc99_fwscanf.c += -fexceptions
+CFLAGS-isoc99_vwscanf.c += -fexceptions
+CFLAGS-isoc99_vfwscanf.c += -fexceptions
CPPFLAGS += $(libio-mtsafe)