aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog21
-rw-r--r--gcc/Makefile.in3
-rw-r--r--gcc/config/t-vxworks4
-rwxr-xr-xgcc/configure20
-rw-r--r--gcc/configure.ac14
-rw-r--r--gcc/po/ChangeLog6
-rw-r--r--gcc/po/EXCLUDES10
-rw-r--r--libgcc/ChangeLog14
-rw-r--r--libgcc/Makefile.in3
-rw-r--r--libgcc/config/gthr-lynx.h (renamed from gcc/gthr-lynx.h)4
-rw-r--r--libgcc/config/gthr-posix.h (renamed from gcc/gthr-posix.h)0
-rw-r--r--libgcc/config/gthr-rtems.h (renamed from gcc/gthr-rtems.h)0
-rw-r--r--libgcc/config/gthr-vxworks.h (renamed from gcc/gthr-vxworks.h)5
-rw-r--r--libgcc/config/i386/gthr-win32.c5
-rw-r--r--libgcc/config/i386/gthr-win32.h (renamed from gcc/gthr-win32.h)0
-rw-r--r--libgcc/config/mips/gthr-mipssde.h (renamed from gcc/gthr-mipssde.h)0
-rw-r--r--libgcc/config/pa/gthr-dce.h (renamed from gcc/gthr-dce.h)0
-rw-r--r--libgcc/config/rs6000/gthr-aix.h (renamed from gcc/gthr-aix.h)4
-rw-r--r--libgcc/config/s390/gthr-tpf.h (renamed from gcc/gthr-tpf.h)0
-rw-r--r--libgcc/configure52
-rw-r--r--libgcc/configure.ac15
-rw-r--r--libgcc/gthr-single.h (renamed from gcc/gthr-single.h)0
-rw-r--r--libgcc/gthr.h (renamed from gcc/gthr.h)20
-rw-r--r--libgfortran/ChangeLog10
-rw-r--r--libgfortran/Makefile.am4
-rw-r--r--libgfortran/Makefile.in4
-rw-r--r--libgfortran/acinclude.m411
-rw-r--r--libgfortran/config.h.in3
-rwxr-xr-xlibgfortran/configure19
-rw-r--r--libgfortran/configure.ac3
-rw-r--r--libobjc/ChangeLog7
-rw-r--r--libobjc/Makefile.in1
-rw-r--r--libobjc/config.h.in3
-rwxr-xr-xlibobjc/configure14
-rw-r--r--libobjc/configure.ac9
-rw-r--r--libstdc++-v3/ChangeLog20
-rw-r--r--libstdc++-v3/Makefile.in2
-rw-r--r--libstdc++-v3/acinclude.m430
-rw-r--r--libstdc++-v3/config.h.in4
-rwxr-xr-xlibstdc++-v3/configure44
-rw-r--r--libstdc++-v3/doc/Makefile.in2
-rw-r--r--libstdc++-v3/include/Makefile.am25
-rw-r--r--libstdc++-v3/include/Makefile.in27
-rw-r--r--libstdc++-v3/libsupc++/Makefile.in2
-rw-r--r--libstdc++-v3/po/Makefile.in2
-rw-r--r--libstdc++-v3/python/Makefile.in2
-rw-r--r--libstdc++-v3/src/Makefile.in2
-rw-r--r--libstdc++-v3/testsuite/Makefile.in2
48 files changed, 192 insertions, 260 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index f1e4860d1b9..817abbde214 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,4 +1,25 @@
2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ * gthr-single.h, gthr.h: Move to ../libgcc.
+ * gthr-aix.h: Move to ../libgcc/config/rs6000.
+ * gthr-dce.h: Move to ../libgcc/config/pa.
+ * gthr-lynx.h: Move to ../libgcc/config.
+ * gthr-mipssde.h: Move to ../libgcc/config/mips.
+ * gthr-posix.h: Move to ../libgcc/config.
+ * gthr-rtems.h: Likewise.
+ * gthr-tpf.h: Move to ../libgcc/config/s390.
+ * gthr-vxworks.h: Move to ../libgcc/config.
+ * gthr-win32.h: Move to ../libgcc/config/i386.
+ * configure.ac (gthread_flags): Remove
+ (gthr-default.h): Don't create.
+ (thread_file): Don't substitute.
+ * configure: Regenerate.
+ * Makefile.in (GCC_THREAD_FILE): Remove.
+ (GTHREAD_FLAGS): Remove.
+ (libgcc.mvars): Remove GTHREAD_FLAGS.
+ * config/t-vxworks (EXTRA_HEADERS): Remove.
+
+2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Paolo Bonzini <bonzini@gnu.org>
* configure.ac (libgcc_tm_file_list, libgcc_tm_include_list):
diff --git a/gcc/Makefile.in b/gcc/Makefile.in
index cf1c8a7f30b..229e8c10fce 100644
--- a/gcc/Makefile.in
+++ b/gcc/Makefile.in
@@ -532,9 +532,7 @@ lang_opt_files=@lang_opt_files@ $(srcdir)/c-family/c.opt $(srcdir)/common.opt
lang_specs_files=@lang_specs_files@
lang_tree_files=@lang_tree_files@
target_cpu_default=@target_cpu_default@
-GCC_THREAD_FILE=@thread_file@
OBJC_BOEHM_GC=@objc_boehm_gc@
-GTHREAD_FLAGS=@gthread_flags@
extra_modes_file=@extra_modes_file@
extra_opt_files=@extra_opt_files@
host_hook_obj=@out_host_hook_obj@
@@ -1808,7 +1806,6 @@ libgcc-support: libgcc.mvars stmp-int-hdrs $(TCONFIG_H) \
libgcc.mvars: config.status Makefile specs xgcc$(exeext)
: > tmp-libgcc.mvars
echo GCC_CFLAGS = '$(GCC_CFLAGS)' >> tmp-libgcc.mvars
- echo GTHREAD_FLAGS = '$(GTHREAD_FLAGS)' >> tmp-libgcc.mvars
echo INHIBIT_LIBC_CFLAGS = '$(INHIBIT_LIBC_CFLAGS)' >> tmp-libgcc.mvars
echo TARGET_SYSTEM_ROOT = '$(TARGET_SYSTEM_ROOT)' >> tmp-libgcc.mvars
diff --git a/gcc/config/t-vxworks b/gcc/config/t-vxworks
index 9564e1bef55..61d6e710aca 100644
--- a/gcc/config/t-vxworks
+++ b/gcc/config/t-vxworks
@@ -17,10 +17,6 @@
# along with GCC; see the file COPYING3. If not see
# <http://www.gnu.org/licenses/>.
-# Some runtime modules need these. Can't set extra_headers in config.gcc
-# because the paths are always made absolute to the cpu config dir.
-EXTRA_HEADERS += $(srcdir)/gthr-vxworks.h gthr-default.h
-
# Both the kernel and RTP headers provide limits.h.
LIMITS_H_TEST = true
diff --git a/gcc/configure b/gcc/configure
index cb116d22993..3b0b39b484a 100755
--- a/gcc/configure
+++ b/gcc/configure
@@ -621,7 +621,6 @@ tm_p_file_list
tm_defines
tm_include_list
tm_file_list
-thread_file
common_out_object_file
common_out_file
out_object_file
@@ -724,7 +723,6 @@ LIBINTL
USE_NLS
extra_opt_files
extra_modes_file
-gthread_flags
NATIVE_SYSTEM_HEADER_DIR
objext
manext
@@ -11353,19 +11351,6 @@ if test x${thread_file} = x; then
thread_file=${target_thread_file}
fi
-# Make gthr-default.h if we have a thread file.
-gthread_flags=
-if test $thread_file != single; then
- echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h-t
- if diff gthr-default.h-t gthr-default.h 2>/dev/null; then
- rm -f gthr-default.h-t
- else
- mv -f gthr-default.h-t gthr-default.h
- fi
- gthread_flags=-DHAVE_GTHR_DEFAULT
-fi
-
-
# --------
# UNSORTED
# --------
@@ -18059,7 +18044,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 18062 "configure"
+#line 18047 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -18165,7 +18150,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 18168 "configure"
+#line 18153 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -27007,7 +26992,6 @@ fi
-
# Echo link setup.
if test x${build} = x${host} ; then
if test x${host} = x${target} ; then
diff --git a/gcc/configure.ac b/gcc/configure.ac
index 6ef0b84c6da..dd6cf2f17f3 100644
--- a/gcc/configure.ac
+++ b/gcc/configure.ac
@@ -1416,19 +1416,6 @@ if test x${thread_file} = x; then
thread_file=${target_thread_file}
fi
-# Make gthr-default.h if we have a thread file.
-gthread_flags=
-if test $thread_file != single; then
- echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h-t
- if diff gthr-default.h-t gthr-default.h 2>/dev/null; then
- rm -f gthr-default.h-t
- else
- mv -f gthr-default.h-t gthr-default.h
- fi
- gthread_flags=-DHAVE_GTHR_DEFAULT
-fi
-AC_SUBST(gthread_flags)
-
# --------
# UNSORTED
# --------
@@ -4961,7 +4948,6 @@ AC_SUBST(out_file)
AC_SUBST(out_object_file)
AC_SUBST(common_out_file)
AC_SUBST(common_out_object_file)
-AC_SUBST(thread_file)
AC_SUBST(tm_file_list)
AC_SUBST(tm_include_list)
AC_SUBST(tm_defines)
diff --git a/gcc/po/ChangeLog b/gcc/po/ChangeLog
index 5cc12f4372c..c7164125d0c 100644
--- a/gcc/po/ChangeLog
+++ b/gcc/po/ChangeLog
@@ -1,5 +1,11 @@
2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+ * EXCLUDES (gthr-aix.h, gthr-dce.h, gthr-posix.c, gthr-posix.h)
+ (gthr-rtems.h, gthr-single.h, gthr-solaris.h, gthr-vxworks.h)
+ (gthr-win32.h, gthr.h): Remove.
+
+2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
* EXCLUDES (config/vxlib.c, gbl-ctors.h, libgcc2.c, libgcc2.h)
(longlong.h): Remove.
diff --git a/gcc/po/EXCLUDES b/gcc/po/EXCLUDES
index c969910fa56..e04b9239363 100644
--- a/gcc/po/EXCLUDES
+++ b/gcc/po/EXCLUDES
@@ -24,16 +24,6 @@
# These files are part of libgcc, or target headers provided by gcc.
gcov-io.h
gcov-iov.c
-gthr-aix.h
-gthr-dce.h
-gthr-posix.c
-gthr-posix.h
-gthr-rtems.h
-gthr-single.h
-gthr-solaris.h
-gthr-vxworks.h
-gthr-win32.h
-gthr.h
limitx.h
limity.h
diff --git a/libgcc/ChangeLog b/libgcc/ChangeLog
index c169190c397..1bbe29afd05 100644
--- a/libgcc/ChangeLog
+++ b/libgcc/ChangeLog
@@ -1,5 +1,19 @@
2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+ * gthr-single.h, gthr.h: New files.
+ * config/gthr-lynx.h, config/gthr-posix.h., config/gthr-rtems.h,
+ config/gthr-vxworks.h, config/i386/gthr-win32.h,
+ config/mips/gthr-mipssde.h, config/pa/gthr-dce.h,
+ config/rs6000/gthr-aix.h, config/s390/gthr-tpf.h: New files.
+ * config/i386/gthr-win32.c: Include "gthr-win32.h".
+ * configure.ac (thread_header): New variable.
+ Set it depending on target_thread_file.
+ (gthr-default.h): Link from $thread_header.
+ * configure: Regenerate.
+ * Makefile.in (LIBGCC2_CFLAGS): Remove $(GTHREAD_FLAGS).
+
+2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
* configure.ac (tm_file_): New variable.
Determine from tm_file.
(tm_file, tm_defines): Substitute.
diff --git a/libgcc/Makefile.in b/libgcc/Makefile.in
index 2ea6ca69d64..8f0c02ff3ec 100644
--- a/libgcc/Makefile.in
+++ b/libgcc/Makefile.in
@@ -223,8 +223,7 @@ endif
#
LIBGCC2_DEBUG_CFLAGS = -g
LIBGCC2_CFLAGS = -O2 $(LIBGCC2_INCLUDES) $(GCC_CFLAGS) $(HOST_LIBGCC2_CFLAGS) \
- $(LIBGCC2_DEBUG_CFLAGS) $(GTHREAD_FLAGS) \
- -DIN_LIBGCC2 \
+ $(LIBGCC2_DEBUG_CFLAGS) -DIN_LIBGCC2 \
-fbuilding-libgcc -fno-stack-protector \
$(INHIBIT_LIBC_CFLAGS)
diff --git a/gcc/gthr-lynx.h b/libgcc/config/gthr-lynx.h
index 13b81d2fedb..c98c2e6693e 100644
--- a/gcc/gthr-lynx.h
+++ b/libgcc/config/gthr-lynx.h
@@ -1,7 +1,7 @@
/* Threads compatibility routines for libgcc2 and libobjc for
LynxOS. */
/* Compile this one with gcc. */
-/* Copyright (C) 2004, 2008, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 2004, 2008, 2009, 2011 Free Software Foundation, Inc.
This file is part of GCC.
@@ -52,7 +52,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
#undef GTHREAD_USE_WEAK
#define GTHREAD_USE_WEAK 0
-#include "gthr-posix.h"
+#include "config/gthr-posix.h"
#else
#include "gthr-single.h"
diff --git a/gcc/gthr-posix.h b/libgcc/config/gthr-posix.h
index 46054f6a7c2..46054f6a7c2 100644
--- a/gcc/gthr-posix.h
+++ b/libgcc/config/gthr-posix.h
diff --git a/gcc/gthr-rtems.h b/libgcc/config/gthr-rtems.h
index c5bd52292cf..c5bd52292cf 100644
--- a/gcc/gthr-rtems.h
+++ b/libgcc/config/gthr-rtems.h
diff --git a/gcc/gthr-vxworks.h b/libgcc/config/gthr-vxworks.h
index d4da14ef492..2346b528660 100644
--- a/gcc/gthr-vxworks.h
+++ b/libgcc/config/gthr-vxworks.h
@@ -1,6 +1,7 @@
/* Threads compatibility routines for libgcc2 and libobjc for VxWorks. */
/* Compile this one with gcc. */
-/* Copyright (C) 1997, 1999, 2000, 2008, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 1999, 2000, 2008, 2009, 2011
+ Free Software Foundation, Inc.
Contributed by Mike Stump <mrs@wrs.com>.
This file is part of GCC.
@@ -30,7 +31,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
#ifdef _LIBOBJC
/* libobjc requires the optional pthreads component. */
-#include "gthr-posix.h"
+#include "config/gthr-posix.h"
#else
#ifdef __cplusplus
diff --git a/libgcc/config/i386/gthr-win32.c b/libgcc/config/i386/gthr-win32.c
index 46ecb0d4b26..ab1b69fd4cf 100644
--- a/libgcc/config/i386/gthr-win32.c
+++ b/libgcc/config/i386/gthr-win32.c
@@ -1,7 +1,8 @@
/* Implementation of W32-specific threads compatibility routines for
libgcc2. */
-/* Copyright (C) 1999, 2000, 2002, 2004, 2008, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1999, 2000, 2002, 2004, 2008, 2009, 2011
+ Free Software Foundation, Inc.
Contributed by Mumit Khan <khan@xraylith.wisc.edu>.
Modified and moved to separate file by Danny Smith
<dannysmith@users.sourceforge.net>.
@@ -33,7 +34,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
#endif
#undef __GTHREAD_I486_INLINE_LOCK_PRIMITIVES
#define __GTHREAD_I486_INLINE_LOCK_PRIMITIVES
-#include <gthr-win32.h>
+#include "gthr-win32.h"
/* Windows32 threads specific definitions. The windows32 threading model
does not map well into pthread-inspired gcc's threading model, and so
diff --git a/gcc/gthr-win32.h b/libgcc/config/i386/gthr-win32.h
index 53f8396cc81..53f8396cc81 100644
--- a/gcc/gthr-win32.h
+++ b/libgcc/config/i386/gthr-win32.h
diff --git a/gcc/gthr-mipssde.h b/libgcc/config/mips/gthr-mipssde.h
index 34f9b6cf54b..34f9b6cf54b 100644
--- a/gcc/gthr-mipssde.h
+++ b/libgcc/config/mips/gthr-mipssde.h
diff --git a/gcc/gthr-dce.h b/libgcc/config/pa/gthr-dce.h
index d32155a9352..d32155a9352 100644
--- a/gcc/gthr-dce.h
+++ b/libgcc/config/pa/gthr-dce.h
diff --git a/gcc/gthr-aix.h b/libgcc/config/rs6000/gthr-aix.h
index 6827e8f316d..342f09187f0 100644
--- a/gcc/gthr-aix.h
+++ b/libgcc/config/rs6000/gthr-aix.h
@@ -1,6 +1,6 @@
/* Threads compatibility routines for libgcc2 and libobjc. */
/* Compile this one with gcc. */
-/* Copyright (C) 2000, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 2000, 2009, 2011 Free Software Foundation, Inc.
This file is part of GCC.
@@ -27,7 +27,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
#define GCC_GTHR_AIX_H
#ifdef _THREAD_SAFE
-#include "gthr-posix.h"
+#include "config/gthr-posix.h"
#else
#include "gthr-single.h"
#endif
diff --git a/gcc/gthr-tpf.h b/libgcc/config/s390/gthr-tpf.h
index fb23e91cfcd..fb23e91cfcd 100644
--- a/gcc/gthr-tpf.h
+++ b/libgcc/config/s390/gthr-tpf.h
diff --git a/libgcc/configure b/libgcc/configure
index 63b91b47a55..0d91645ed67 100644
--- a/libgcc/configure
+++ b/libgcc/configure
@@ -2273,7 +2273,7 @@ case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
- # FIXME: Do we need something for CFLAGS below?
+
case "${host}" in
# PIC is the default on some targets or must not be used.
@@ -2288,24 +2288,23 @@ case "${host}" in
hppa*64*-*-hpux*)
# PIC is the default for 64-bit PA HP-UX.
;;
- i3456786-*-cygwin* | i3456786-*-mingw* | x86_64-*-mingw*)
+ i[34567]86-*-cygwin* | i[34567]86-*-mingw* | x86_64-*-mingw*)
;;
- i3456786-*-interix3*)
+ i[34567]86-*-interix3*)
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
# Instead, we relocate shared libraries at runtime.
;;
- i3456786-*-nto-qnx*)
+ i[34567]86-*-nto-qnx*)
# QNX uses GNU C++, but need to define -shared option too, otherwise
# it will coredump.
PICFLAG='-fPIC -shared'
;;
- i3456786-pc-msdosdjgpp*)
+ i[34567]86-pc-msdosdjgpp*)
# DJGPP does not support shared libraries at all.
;;
ia64*-*-hpux*)
# On IA64 HP-UX, PIC is the default but the pic flag
# sets the default TLS model and affects inlining.
- # FIXME: Still in gcc 4.7?
PICFLAG=-fPIC
;;
mips-sgi-irix6*)
@@ -2317,7 +2316,7 @@ case "${host}" in
# Some targets support both -fPIC and -fpic, but prefer the latter.
# FIXME: Why?
- i3456786-*-* | x86_64-*-*)
+ i[34567]86-*-* | x86_64-*-*)
PICFLAG=-fpic
;;
m68k-*-*)
@@ -2327,7 +2326,7 @@ case "${host}" in
PICFLAG=-fpic
;;
# FIXME: Override -fPIC default in libgcc only?
- sh-*-linux* | sh2346lbe*-*-linux*)
+ sh-*-linux* | sh[2346lbe]*-*-linux*)
PICFLAG=-fpic
;;
# FIXME: Simplify to sh*-*-netbsd*?
@@ -2335,22 +2334,22 @@ case "${host}" in
sh64-*-netbsd* | sh64l*-*-netbsd*)
PICFLAG=-fpic
;;
- sparc*-*-*)
- # FIXME: This could be done everywhere -fpic and -fPIC differ.
- case "${CFLAGS}" in
- *-fpic*)
- PICFLAG=-fpic
- ;;
- *)
- PICFLAG=-fPIC
- ;;
- esac ;;
# Default to -fPIC unless specified otherwise.
*)
PICFLAG=-fPIC
;;
esac
+# If the user explicitly uses -fpic/-fPIC, keep that.
+case "${CFLAGS}" in
+ *-fpic*)
+ PICFLAG=-fpic
+ ;;
+ *-fPIC*)
+ PICFLAG=-fPIC
+ ;;
+esac
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-version-specific-runtime-libs" >&5
@@ -4797,6 +4796,20 @@ tm_file="${tm_file_}"
+# Map from thread model to thread header.
+case $target_thread_file in
+ aix) thread_header=config/rs6000/gthr-aix.h ;;
+ dce) thread_header=config/pa/gthr-dce.h ;;
+ lynx) thread_header=config/gthr-lynx.h ;;
+ mipssde) thread_header=config/mips/gthr-mipssde.h ;;
+ posix) thread_header=config/gthr-posix.h ;;
+ rtems) thread_header=config/gthr-rtems.h ;;
+ single) thread_header=gthr-single.h ;;
+ tpf) thread_header=config/s390/gthr-tpf.h ;;
+ vxworks) thread_header=config/gthr-vxworks.h ;;
+ win32) thread_header=config/i386/gthr-win32.h ;;
+esac
+
# Substitute configuration variables
@@ -4809,6 +4822,8 @@ ac_config_links="$ac_config_links md-unwind-support.h:config/$md_unwind_header"
ac_config_links="$ac_config_links sfp-machine.h:config/$sfp_machine_header"
+ac_config_links="$ac_config_links gthr-default.h:$thread_header"
+
# We need multilib support.
ac_config_files="$ac_config_files Makefile"
@@ -5538,6 +5553,7 @@ do
"unwind.h") CONFIG_LINKS="$CONFIG_LINKS unwind.h:$unwind_header" ;;
"md-unwind-support.h") CONFIG_LINKS="$CONFIG_LINKS md-unwind-support.h:config/$md_unwind_header" ;;
"sfp-machine.h") CONFIG_LINKS="$CONFIG_LINKS sfp-machine.h:config/$sfp_machine_header" ;;
+ "gthr-default.h") CONFIG_LINKS="$CONFIG_LINKS gthr-default.h:$thread_header" ;;
"Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
"default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
diff --git a/libgcc/configure.ac b/libgcc/configure.ac
index 303a95ff54b..a505257ac23 100644
--- a/libgcc/configure.ac
+++ b/libgcc/configure.ac
@@ -364,6 +364,20 @@ tm_file="${tm_file_}"
AC_SUBST(tm_file)
AC_SUBST(tm_defines)
+# Map from thread model to thread header.
+case $target_thread_file in
+ aix) thread_header=config/rs6000/gthr-aix.h ;;
+ dce) thread_header=config/pa/gthr-dce.h ;;
+ lynx) thread_header=config/gthr-lynx.h ;;
+ mipssde) thread_header=config/mips/gthr-mipssde.h ;;
+ posix) thread_header=config/gthr-posix.h ;;
+ rtems) thread_header=config/gthr-rtems.h ;;
+ single) thread_header=gthr-single.h ;;
+ tpf) thread_header=config/s390/gthr-tpf.h ;;
+ vxworks) thread_header=config/gthr-vxworks.h ;;
+ win32) thread_header=config/i386/gthr-win32.h ;;
+esac
+
# Substitute configuration variables
AC_SUBST(cpu_type)
AC_SUBST(extra_parts)
@@ -372,6 +386,7 @@ AC_CONFIG_LINKS([enable-execute-stack.c:$enable_execute_stack])
AC_CONFIG_LINKS([unwind.h:$unwind_header])
AC_CONFIG_LINKS([md-unwind-support.h:config/$md_unwind_header])
AC_CONFIG_LINKS([sfp-machine.h:config/$sfp_machine_header])
+AC_CONFIG_LINKS([gthr-default.h:$thread_header])
# We need multilib support.
AC_CONFIG_FILES([Makefile])
diff --git a/gcc/gthr-single.h b/libgcc/gthr-single.h
index 357528ad1f1..357528ad1f1 100644
--- a/gcc/gthr-single.h
+++ b/libgcc/gthr-single.h
diff --git a/gcc/gthr.h b/libgcc/gthr.h
index 0c7bfb17aa3..607c26eb563 100644
--- a/gcc/gthr.h
+++ b/libgcc/gthr.h
@@ -132,23 +132,8 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
__gthread_recursive_mutex_t *mutex,
const __gthread_time_t *abs_time)
- Currently supported threads packages are
- TPF threads with -D__tpf__
- POSIX/Unix98 threads with -D_PTHREADS
- DCE threads with -D_DCE_THREADS
-
*/
-/* Check first for thread specific defines. */
-#if defined (__tpf__)
-#include "gthr-tpf.h"
-#elif _PTHREADS
-#include "gthr-posix.h"
-#elif _DCE_THREADS
-#include "gthr-dce.h"
-
-/* Include GTHREAD_FILE if one is defined. */
-#elif defined(HAVE_GTHR_DEFAULT)
#if SUPPORTS_WEAK
#ifndef GTHREAD_USE_WEAK
#define GTHREAD_USE_WEAK 1
@@ -156,11 +141,6 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
#endif
#include "gthr-default.h"
-/* Fallback to single thread definitions. */
-#else
-#include "gthr-single.h"
-#endif
-
#ifndef HIDE_EXPORTS
#pragma GCC visibility pop
#endif
diff --git a/libgfortran/ChangeLog b/libgfortran/ChangeLog
index a022ee2ec63..264f196d9df 100644
--- a/libgfortran/ChangeLog
+++ b/libgfortran/ChangeLog
@@ -1,3 +1,13 @@
+2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ * Makefile.am (AM_CPPFLAGS): Add
+ -I$(srcdir)/$(MULTISRCTOP)../libgcc, -I$(MULTIBUILDTOP)../libgcc.
+ * Makefile.in: Regenerate.
+ * acinclude.m4 (LIBGFOR_CHECK_GTHR_DEFAULT): Remove.
+ * configure.ac (LIBGFOR_CHECK_GTHR_DEFAULT): Likewise.
+ * configure: Regenerate.
+ * config.h.in: Regenerate.
+
2011-11-01 Janne Blomqvist <jb@gcc.gnu.org>
* io/io.h (next_available_newunit): Remove prototype.
diff --git a/libgfortran/Makefile.am b/libgfortran/Makefile.am
index ce0d7250328..350b7161059 100644
--- a/libgfortran/Makefile.am
+++ b/libgfortran/Makefile.am
@@ -56,7 +56,9 @@ libcaf_single_la_LINK = $(LINK) $(libcaf_single_la_LDFLAGS)
## use -iquote
AM_CPPFLAGS = -iquote$(srcdir)/io -I$(srcdir)/$(MULTISRCTOP)../gcc \
-I$(srcdir)/$(MULTISRCTOP)../gcc/config $(LIBQUADINCLUDE) \
- -I$(MULTIBUILDTOP)../../$(host_subdir)/gcc
+ -I$(MULTIBUILDTOP)../../$(host_subdir)/gcc \
+ -I$(srcdir)/$(MULTISRCTOP)../libgcc \
+ -I$(MULTIBUILDTOP)../libgcc
# Fortran rules for complex multiplication and division
AM_CFLAGS += -fcx-fortran-rules
diff --git a/libgfortran/Makefile.in b/libgfortran/Makefile.in
index d41b7bb2b82..80a6c60968d 100644
--- a/libgfortran/Makefile.in
+++ b/libgfortran/Makefile.in
@@ -506,7 +506,9 @@ libcaf_single_la_DEPENDENCIES = caf/libcaf.h
libcaf_single_la_LINK = $(LINK) $(libcaf_single_la_LDFLAGS)
AM_CPPFLAGS = -iquote$(srcdir)/io -I$(srcdir)/$(MULTISRCTOP)../gcc \
-I$(srcdir)/$(MULTISRCTOP)../gcc/config $(LIBQUADINCLUDE) \
- -I$(MULTIBUILDTOP)../../$(host_subdir)/gcc
+ -I$(MULTIBUILDTOP)../../$(host_subdir)/gcc \
+ -I$(srcdir)/$(MULTISRCTOP)../libgcc \
+ -I$(MULTIBUILDTOP)../libgcc
gfor_io_src = \
io/close.c \
diff --git a/libgfortran/acinclude.m4 b/libgfortran/acinclude.m4
index 92e027177b5..b6cb40430af 100644
--- a/libgfortran/acinclude.m4
+++ b/libgfortran/acinclude.m4
@@ -83,17 +83,6 @@ if (foovar > 10) return __sync_add_and_fetch (&foovar, -1);]])],
[Define to 1 if the target supports __sync_fetch_and_add])
fi])
-dnl Check if threads are supported.
-AC_DEFUN([LIBGFOR_CHECK_GTHR_DEFAULT], [
- AC_CACHE_CHECK([configured target thread model],
- libgfor_cv_target_thread_file, [
-libgfor_cv_target_thread_file=`$CC -v 2>&1 | sed -n 's/^Thread model: //p'`])
-
- if test $libgfor_cv_target_thread_file != single; then
- AC_DEFINE(HAVE_GTHR_DEFAULT, 1,
- [Define if the compiler has a thread header that is non single.])
- fi])
-
dnl Check for pragma weak.
AC_DEFUN([LIBGFOR_GTHREAD_WEAK], [
AC_CACHE_CHECK([whether pragma weak works],
diff --git a/libgfortran/config.h.in b/libgfortran/config.h.in
index 57f66b51ab9..708ec7cd02d 100644
--- a/libgfortran/config.h.in
+++ b/libgfortran/config.h.in
@@ -483,9 +483,6 @@
/* Define to 1 if you have the `gmtime_r' function. */
#undef HAVE_GMTIME_R
-/* Define if the compiler has a thread header that is non single. */
-#undef HAVE_GTHR_DEFAULT
-
/* libm includes hypot */
#undef HAVE_HYPOT
diff --git a/libgfortran/configure b/libgfortran/configure
index a716ff37faf..3a1174a1237 100755
--- a/libgfortran/configure
+++ b/libgfortran/configure
@@ -25704,25 +25704,6 @@ $as_echo "#define HAVE_SYNC_FETCH_AND_ADD 1" >>confdefs.h
fi
-# Check out thread support.
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking configured target thread model" >&5
-$as_echo_n "checking configured target thread model... " >&6; }
-if test "${libgfor_cv_target_thread_file+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
-
-libgfor_cv_target_thread_file=`$CC -v 2>&1 | sed -n 's/^Thread model: //p'`
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libgfor_cv_target_thread_file" >&5
-$as_echo "$libgfor_cv_target_thread_file" >&6; }
-
- if test $libgfor_cv_target_thread_file != single; then
-
-$as_echo "#define HAVE_GTHR_DEFAULT 1" >>confdefs.h
-
- fi
-
# Check out #pragma weak.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pragma weak works" >&5
diff --git a/libgfortran/configure.ac b/libgfortran/configure.ac
index 74cfe441a75..447ea9df998 100644
--- a/libgfortran/configure.ac
+++ b/libgfortran/configure.ac
@@ -550,9 +550,6 @@ LIBGFOR_CHECK_ATTRIBUTE_ALIAS
# Check out sync builtins support.
LIBGFOR_CHECK_SYNC_FETCH_AND_ADD
-# Check out thread support.
-LIBGFOR_CHECK_GTHR_DEFAULT
-
# Check out #pragma weak.
LIBGFOR_GTHREAD_WEAK
diff --git a/libobjc/ChangeLog b/libobjc/ChangeLog
index 86e8c139194..474849480e0 100644
--- a/libobjc/ChangeLog
+++ b/libobjc/ChangeLog
@@ -1,3 +1,10 @@
+2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ * Makefile.in (INCLUDES): Add -I$(MULTIBUILDTOP)../libgcc.
+ * configure.ac (target_thread_file, HAVE_GTHR_DEFAULT): Remove.
+ * configure: Regenerate.
+ * config.h.in: Regenerate.
+
2011-10-17 Paul Brook <paul@codesourcery.com>
Matthias Klose <doko@ubuntu.com>
diff --git a/libobjc/Makefile.in b/libobjc/Makefile.in
index 0935ccd98d6..1427bac43b2 100644
--- a/libobjc/Makefile.in
+++ b/libobjc/Makefile.in
@@ -102,6 +102,7 @@ INCLUDES = -I$(srcdir)/$(MULTISRCTOP)../gcc \
-I$(srcdir)/$(MULTISRCTOP)../gcc/config \
-I$(MULTIBUILDTOP)../../$(host_subdir)/gcc \
-I$(srcdir)/$(MULTISRCTOP)../libgcc \
+ -I$(MULTIBUILDTOP)../libgcc \
-I$(srcdir)/$(MULTISRCTOP)../include \
$(OBJC_BOEHM_GC_INCLUDES)
diff --git a/libobjc/config.h.in b/libobjc/config.h.in
index d9c8172d258..c055e7c1909 100644
--- a/libobjc/config.h.in
+++ b/libobjc/config.h.in
@@ -6,9 +6,6 @@
/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
-/* Define if the compiler has a thread header that is non single. */
-#undef HAVE_GTHR_DEFAULT
-
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
diff --git a/libobjc/configure b/libobjc/configure
index c68cde0f806..59e3d98a7a5 100755
--- a/libobjc/configure
+++ b/libobjc/configure
@@ -11248,18 +11248,6 @@ done
# Miscellanea
# -----------
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread model used by GCC" >&5
-$as_echo_n "checking for thread model used by GCC... " >&6; }
-target_thread_file=`$CC -v 2>&1 | sed -n 's/^Thread model: //p'`
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $target_thread_file" >&5
-$as_echo "$target_thread_file" >&6; }
-
-if test $target_thread_file != single; then
-
-$as_echo "#define HAVE_GTHR_DEFAULT 1" >>confdefs.h
-
-fi
-
# Check if we have thread-local storage
@@ -11483,7 +11471,7 @@ if test "${enable_sjlj_exceptions+set}" = set; then :
enableval=$enable_sjlj_exceptions; :
else
cat > conftest.$ac_ext << EOF
-#line 11486 "configure"
+#line 11474 "configure"
@interface Frob
@end
@implementation Frob
diff --git a/libobjc/configure.ac b/libobjc/configure.ac
index dd303fff065..52599e6019e 100644
--- a/libobjc/configure.ac
+++ b/libobjc/configure.ac
@@ -217,15 +217,6 @@ AC_CHECK_HEADERS(sched.h)
# Miscellanea
# -----------
-AC_MSG_CHECKING([for thread model used by GCC])
-target_thread_file=`$CC -v 2>&1 | sed -n 's/^Thread model: //p'`
-AC_MSG_RESULT([$target_thread_file])
-
-if test $target_thread_file != single; then
- AC_DEFINE(HAVE_GTHR_DEFAULT, 1,
- [Define if the compiler has a thread header that is non single.])
-fi
-
# Check if we have thread-local storage
GCC_CHECK_TLS
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index 82a0b911412..7e00e2a382b 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -27,6 +27,26 @@
* testsuite/26_numerics/random/shuffle_order_engine/
operators/serialize.cc: Likewise.
+2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ * acinclude.m4 (GLIBCXX_CONFIGURE): Determine and substitute
+ toplevel_builddir.
+ (GLIBCXX_ENABLE_THREADS): Remove glibcxx_thread_h,
+ HAVE_GTHR_DEFAULT, enable_thread.
+ (GLIBCXX_CHECK_GTHREADS): Reflect gthr move to libgcc.
+ * include/Makefile.am (thread_host_headers): Remove
+ ${host_builddir}/gthr-tpf.h.
+ (${host_builddir}/gthr.h): Reflect gthr move to libgcc.
+ Use $<.
+ (${host_builddir}/gthr-single.h): Likewise.
+ (${host_builddir}/gthr-posix.h): Likewise.
+ (${host_builddir}/gthr-tpf.h): Remove.
+ (${host_builddir}/gthr-default.h): Likewise.
+ * configure, config.h.in: Regenerate.
+ * Makefile.in, doc/Makefile.in, include/Makefile.in,
+ libsupc++/Makefile.in, po/Makefile.in, python/Makefile.in,
+ src/Makefile.intestsuite/Makefile.in: Regenerate.
+
2011-11-02 Benjamin Kosnik <bkoz@redhat.com>
* include/bits/c++config: Add tr2 to versioned namespaces.
diff --git a/libstdc++-v3/Makefile.in b/libstdc++-v3/Makefile.in
index 272c4eeea40..2284126ab06 100644
--- a/libstdc++-v3/Makefile.in
+++ b/libstdc++-v3/Makefile.in
@@ -239,7 +239,6 @@ glibcxx_builddir = @glibcxx_builddir@
glibcxx_localedir = @glibcxx_localedir@
glibcxx_prefixdir = @glibcxx_prefixdir@
glibcxx_srcdir = @glibcxx_srcdir@
-glibcxx_thread_h = @glibcxx_thread_h@
glibcxx_toolexecdir = @glibcxx_toolexecdir@
glibcxx_toolexeclibdir = @glibcxx_toolexeclibdir@
gxx_include_dir = @gxx_include_dir@
@@ -279,6 +278,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+toplevel_builddir = @toplevel_builddir@
toplevel_srcdir = @toplevel_srcdir@
# May be used by various substitution variables.
diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4
index 9382250d057..684a2958ce8 100644
--- a/libstdc++-v3/acinclude.m4
+++ b/libstdc++-v3/acinclude.m4
@@ -35,6 +35,7 @@ dnl SUBDIRS
dnl Substs:
dnl glibcxx_builddir (absolute path)
dnl glibcxx_srcdir (absolute path)
+dnl toplevel_builddir (absolute path)
dnl toplevel_srcdir (absolute path)
dnl with_cross_host
dnl with_newlib
@@ -59,9 +60,11 @@ AC_DEFUN([GLIBCXX_CONFIGURE], [
[\\/$]* | ?:[\\/]*) glibcxx_srcdir=${srcdir} ;;
*) glibcxx_srcdir=`cd "$srcdir" && ${PWDCMD-pwd} || echo "$srcdir"` ;;
esac
+ toplevel_builddir=${glibcxx_builddir}/..
toplevel_srcdir=${glibcxx_srcdir}/..
AC_SUBST(glibcxx_builddir)
AC_SUBST(glibcxx_srcdir)
+ AC_SUBST(toplevel_builddir)
AC_SUBST(toplevel_srcdir)
# We use these options to decide which functions to include. They are
@@ -3315,34 +3318,10 @@ dnl having to write complex code (the sed commands to clean the macro
dnl namespace are complex and fragile enough as it is). We must also
dnl add a relative path so that -I- is supported properly.
dnl
-dnl Substs:
-dnl glibcxx_thread_h
-dnl
-dnl Defines:
-dnl HAVE_GTHR_DEFAULT
-dnl
AC_DEFUN([GLIBCXX_ENABLE_THREADS], [
AC_MSG_CHECKING([for thread model used by GCC])
target_thread_file=`$CXX -v 2>&1 | sed -n 's/^Thread model: //p'`
AC_MSG_RESULT([$target_thread_file])
-
- if test $target_thread_file != single; then
- AC_DEFINE(HAVE_GTHR_DEFAULT, 1,
- [Define if gthr-default.h exists
- (meaning that threading support is enabled).])
- fi
-
- glibcxx_thread_h=gthr-$target_thread_file.h
-
- dnl Check for __GTHREADS define.
- gthread_file=${toplevel_srcdir}/gcc/${glibcxx_thread_h}
- if grep __GTHREADS $gthread_file >/dev/null 2>&1 ; then
- enable_thread=yes
- else
- enable_thread=no
- fi
-
- AC_SUBST(glibcxx_thread_h)
])
@@ -3356,7 +3335,8 @@ AC_DEFUN([GLIBCXX_CHECK_GTHREADS], [
AC_LANG_CPLUSPLUS
ac_save_CXXFLAGS="$CXXFLAGS"
- CXXFLAGS="$CXXFLAGS -fno-exceptions -I${toplevel_srcdir}/gcc"
+ CXXFLAGS="$CXXFLAGS -fno-exceptions \
+ -I${toplevel_srcdir}/libgcc -I${toplevel_builddir}/libgcc"
target_thread_file=`$CXX -v 2>&1 | sed -n 's/^Thread model: //p'`
case $target_thread_file in
diff --git a/libstdc++-v3/config.h.in b/libstdc++-v3/config.h.in
index df7effb6a6b..f82d91ad417 100644
--- a/libstdc++-v3/config.h.in
+++ b/libstdc++-v3/config.h.in
@@ -171,10 +171,6 @@
/* Define if _Unwind_GetIPInfo is available. */
#undef HAVE_GETIPINFO
-/* Define if gthr-default.h exists (meaning that threading support is
- enabled). */
-#undef HAVE_GTHR_DEFAULT
-
/* Define to 1 if you have the `hypot' function. */
#undef HAVE_HYPOT
diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
index 77a4abfbadf..428cdc5bd80 100755
--- a/libstdc++-v3/configure
+++ b/libstdc++-v3/configure
@@ -707,7 +707,6 @@ BASIC_FILE_H
CSTDIO_H
SECTION_FLAGS
WERROR
-glibcxx_thread_h
glibcxx_PCHFLAGS
GLIBCXX_BUILD_PCH_FALSE
GLIBCXX_BUILD_PCH_TRUE
@@ -741,6 +740,7 @@ AR
AS
LN_S
toplevel_srcdir
+toplevel_builddir
glibcxx_srcdir
glibcxx_builddir
ac_ct_CXX
@@ -4870,11 +4870,13 @@ $as_echo "$ac_cv_path_EGREP" >&6; }
\\/$* | ?:\\/*) glibcxx_srcdir=${srcdir} ;;
*) glibcxx_srcdir=`cd "$srcdir" && ${PWDCMD-pwd} || echo "$srcdir"` ;;
esac
+ toplevel_builddir=${glibcxx_builddir}/..
toplevel_srcdir=${glibcxx_srcdir}/..
+
# We use these options to decide which functions to include. They are
# set from the top level.
@@ -11485,7 +11487,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11488 "configure"
+#line 11490 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -11591,7 +11593,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11594 "configure"
+#line 11596 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -14949,7 +14951,7 @@ fi
#
# Fake what AC_TRY_COMPILE does. XXX Look at redoing this new-style.
cat > conftest.$ac_ext << EOF
-#line 14952 "configure"
+#line 14954 "configure"
struct S { ~S(); };
void bar();
void foo()
@@ -15077,23 +15079,6 @@ $as_echo_n "checking for thread model used by GCC... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $target_thread_file" >&5
$as_echo "$target_thread_file" >&6; }
- if test $target_thread_file != single; then
-
-$as_echo "#define HAVE_GTHR_DEFAULT 1" >>confdefs.h
-
- fi
-
- glibcxx_thread_h=gthr-$target_thread_file.h
-
- gthread_file=${toplevel_srcdir}/gcc/${glibcxx_thread_h}
- if grep __GTHREADS $gthread_file >/dev/null 2>&1 ; then
- enable_thread=yes
- else
- enable_thread=no
- fi
-
-
-
ac_ext=cpp
@@ -15317,7 +15302,7 @@ $as_echo "$glibcxx_cv_atomic_long_long" >&6; }
# Fake what AC_TRY_COMPILE does.
cat > conftest.$ac_ext << EOF
-#line 15320 "configure"
+#line 15305 "configure"
int main()
{
typedef bool atomic_type;
@@ -15354,7 +15339,7 @@ $as_echo "$glibcxx_cv_atomic_bool" >&6; }
rm -f conftest*
cat > conftest.$ac_ext << EOF
-#line 15357 "configure"
+#line 15342 "configure"
int main()
{
typedef short atomic_type;
@@ -15391,7 +15376,7 @@ $as_echo "$glibcxx_cv_atomic_short" >&6; }
rm -f conftest*
cat > conftest.$ac_ext << EOF
-#line 15394 "configure"
+#line 15379 "configure"
int main()
{
// NB: _Atomic_word not necessarily int.
@@ -15429,7 +15414,7 @@ $as_echo "$glibcxx_cv_atomic_int" >&6; }
rm -f conftest*
cat > conftest.$ac_ext << EOF
-#line 15432 "configure"
+#line 15417 "configure"
int main()
{
typedef long long atomic_type;
@@ -15505,7 +15490,7 @@ $as_echo "$as_me: WARNING: Performance of certain classes will degrade as a resu
# unnecessary for this test.
cat > conftest.$ac_ext << EOF
-#line 15508 "configure"
+#line 15493 "configure"
int main()
{
_Decimal32 d1;
@@ -15547,7 +15532,7 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
# unnecessary for this test.
cat > conftest.$ac_ext << EOF
-#line 15550 "configure"
+#line 15535 "configure"
template<typename T1, typename T2>
struct same
{ typedef T2 type; };
@@ -15581,7 +15566,7 @@ $as_echo "$enable_int128" >&6; }
rm -f conftest*
cat > conftest.$ac_ext << EOF
-#line 15584 "configure"
+#line 15569 "configure"
template<typename T1, typename T2>
struct same
{ typedef T2 type; };
@@ -19821,7 +19806,8 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
ac_save_CXXFLAGS="$CXXFLAGS"
- CXXFLAGS="$CXXFLAGS -fno-exceptions -I${toplevel_srcdir}/gcc"
+ CXXFLAGS="$CXXFLAGS -fno-exceptions \
+ -I${toplevel_srcdir}/libgcc -I${toplevel_builddir}/libgcc"
target_thread_file=`$CXX -v 2>&1 | sed -n 's/^Thread model: //p'`
case $target_thread_file in
diff --git a/libstdc++-v3/doc/Makefile.in b/libstdc++-v3/doc/Makefile.in
index 43045671ccd..8c38839bff7 100644
--- a/libstdc++-v3/doc/Makefile.in
+++ b/libstdc++-v3/doc/Makefile.in
@@ -215,7 +215,6 @@ glibcxx_builddir = @glibcxx_builddir@
glibcxx_localedir = @glibcxx_localedir@
glibcxx_prefixdir = @glibcxx_prefixdir@
glibcxx_srcdir = @glibcxx_srcdir@
-glibcxx_thread_h = @glibcxx_thread_h@
glibcxx_toolexecdir = @glibcxx_toolexecdir@
glibcxx_toolexeclibdir = @glibcxx_toolexeclibdir@
gxx_include_dir = @gxx_include_dir@
@@ -263,6 +262,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+toplevel_builddir = @toplevel_builddir@
toplevel_srcdir = @toplevel_srcdir@
# May be used by various substitution variables.
diff --git a/libstdc++-v3/include/Makefile.am b/libstdc++-v3/include/Makefile.am
index 74acbf0c88a..c342528fe46 100644
--- a/libstdc++-v3/include/Makefile.am
+++ b/libstdc++-v3/include/Makefile.am
@@ -855,7 +855,6 @@ thread_host_headers = \
${host_builddir}/gthr.h \
${host_builddir}/gthr-single.h \
${host_builddir}/gthr-posix.h \
- ${host_builddir}/gthr-tpf.h \
${host_builddir}/gthr-default.h
@@ -1122,43 +1121,35 @@ ${host_builddir}/c++config.h: ${CONFIG_HEADER} \
# Host includes for threads
uppercase = [ABCDEFGHIJKLMNOPQRSTUVWXYZ_]
-${host_builddir}/gthr.h: ${toplevel_srcdir}/gcc/gthr.h stamp-${host_alias}
+${host_builddir}/gthr.h: ${toplevel_srcdir}/libgcc/gthr.h stamp-${host_alias}
sed -e '/^#pragma/b' \
-e '/^#/s/\(${uppercase}${uppercase}*\)/_GLIBCXX_\1/g' \
-e 's/_GLIBCXX_SUPPORTS_WEAK/__GXX_WEAK__/g' \
-e 's,^#include "\(.*\)",#include <bits/\1>,g' \
- < ${toplevel_srcdir}/gcc/gthr.h > $@
+ < $< > $@
-${host_builddir}/gthr-single.h: ${toplevel_srcdir}/gcc/gthr-single.h \
+${host_builddir}/gthr-single.h: ${toplevel_srcdir}/libgcc/gthr-single.h \
stamp-${host_alias}
sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
-e 's/\(GCC${uppercase}*_H\)/_GLIBCXX_\1/g' \
- < ${toplevel_srcdir}/gcc/gthr-single.h > $@
+ < $< > $@
-${host_builddir}/gthr-posix.h: ${toplevel_srcdir}/gcc/gthr-posix.h \
+${host_builddir}/gthr-posix.h: ${toplevel_srcdir}/libgcc/config/gthr-posix.h \
stamp-${host_alias}
sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
-e 's/\(GCC${uppercase}*_H\)/_GLIBCXX_\1/g' \
-e 's/SUPPORTS_WEAK/__GXX_WEAK__/g' \
-e 's/\(${uppercase}*USE_WEAK\)/_GLIBCXX_\1/g' \
- < ${toplevel_srcdir}/gcc/gthr-posix.h > $@
+ < $< > $@
-${host_builddir}/gthr-tpf.h: ${toplevel_srcdir}/gcc/gthr-tpf.h \
- stamp-${host_alias}
- sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
- -e 's/\(GCC${uppercase}*_H\)/_GLIBCXX_\1/g' \
- -e 's/SUPPORTS_WEAK/__GXX_WEAK__/g' \
- -e 's/\(${uppercase}*USE_WEAK\)/_GLIBCXX_\1/g' \
- < ${toplevel_srcdir}/gcc/gthr-tpf.h > $@
-
-${host_builddir}/gthr-default.h: ${toplevel_srcdir}/gcc/${glibcxx_thread_h} \
+${host_builddir}/gthr-default.h: ${toplevel_builddir}/libgcc/gthr-default.h \
stamp-${host_alias}
sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
-e 's/\(GCC${uppercase}*_H\)/_GLIBCXX_\1/g' \
-e 's/SUPPORTS_WEAK/__GXX_WEAK__/g' \
-e 's/\(${uppercase}*USE_WEAK\)/_GLIBCXX_\1/g' \
-e 's,^#include "\(.*\)",#include <bits/\1>,g' \
- < ${toplevel_srcdir}/gcc/${glibcxx_thread_h} > $@
+ < $< > $@
# Build two precompiled C++ includes, stdc++.h.gch/*.gch
${pch1a_output}: ${allstamped} ${host_builddir}/c++config.h ${pch1_source}
diff --git a/libstdc++-v3/include/Makefile.in b/libstdc++-v3/include/Makefile.in
index 8b805ba9acb..40dfb99c689 100644
--- a/libstdc++-v3/include/Makefile.in
+++ b/libstdc++-v3/include/Makefile.in
@@ -213,7 +213,6 @@ glibcxx_builddir = @glibcxx_builddir@
glibcxx_localedir = @glibcxx_localedir@
glibcxx_prefixdir = @glibcxx_prefixdir@
glibcxx_srcdir = @glibcxx_srcdir@
-glibcxx_thread_h = @glibcxx_thread_h@
glibcxx_toolexecdir = @glibcxx_toolexecdir@
glibcxx_toolexeclibdir = @glibcxx_toolexeclibdir@
gxx_include_dir = @gxx_include_dir@
@@ -253,6 +252,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+toplevel_builddir = @toplevel_builddir@
toplevel_srcdir = @toplevel_srcdir@
# May be used by various substitution variables.
@@ -1099,7 +1099,6 @@ thread_host_headers = \
${host_builddir}/gthr.h \
${host_builddir}/gthr-single.h \
${host_builddir}/gthr-posix.h \
- ${host_builddir}/gthr-tpf.h \
${host_builddir}/gthr-default.h
pch1_source = ${glibcxx_srcdir}/include/precompiled/stdc++.h
@@ -1510,43 +1509,35 @@ ${host_builddir}/c++config.h: ${CONFIG_HEADER} \
echo "" >> $@ ;\
echo "#endif // _GLIBCXX_CXX_CONFIG_H" >> $@
-${host_builddir}/gthr.h: ${toplevel_srcdir}/gcc/gthr.h stamp-${host_alias}
+${host_builddir}/gthr.h: ${toplevel_srcdir}/libgcc/gthr.h stamp-${host_alias}
sed -e '/^#pragma/b' \
-e '/^#/s/\(${uppercase}${uppercase}*\)/_GLIBCXX_\1/g' \
-e 's/_GLIBCXX_SUPPORTS_WEAK/__GXX_WEAK__/g' \
-e 's,^#include "\(.*\)",#include <bits/\1>,g' \
- < ${toplevel_srcdir}/gcc/gthr.h > $@
+ < $< > $@
-${host_builddir}/gthr-single.h: ${toplevel_srcdir}/gcc/gthr-single.h \
+${host_builddir}/gthr-single.h: ${toplevel_srcdir}/libgcc/gthr-single.h \
stamp-${host_alias}
sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
-e 's/\(GCC${uppercase}*_H\)/_GLIBCXX_\1/g' \
- < ${toplevel_srcdir}/gcc/gthr-single.h > $@
+ < $< > $@
-${host_builddir}/gthr-posix.h: ${toplevel_srcdir}/gcc/gthr-posix.h \
+${host_builddir}/gthr-posix.h: ${toplevel_srcdir}/libgcc/config/gthr-posix.h \
stamp-${host_alias}
sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
-e 's/\(GCC${uppercase}*_H\)/_GLIBCXX_\1/g' \
-e 's/SUPPORTS_WEAK/__GXX_WEAK__/g' \
-e 's/\(${uppercase}*USE_WEAK\)/_GLIBCXX_\1/g' \
- < ${toplevel_srcdir}/gcc/gthr-posix.h > $@
+ < $< > $@
-${host_builddir}/gthr-tpf.h: ${toplevel_srcdir}/gcc/gthr-tpf.h \
- stamp-${host_alias}
- sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
- -e 's/\(GCC${uppercase}*_H\)/_GLIBCXX_\1/g' \
- -e 's/SUPPORTS_WEAK/__GXX_WEAK__/g' \
- -e 's/\(${uppercase}*USE_WEAK\)/_GLIBCXX_\1/g' \
- < ${toplevel_srcdir}/gcc/gthr-tpf.h > $@
-
-${host_builddir}/gthr-default.h: ${toplevel_srcdir}/gcc/${glibcxx_thread_h} \
+${host_builddir}/gthr-default.h: ${toplevel_builddir}/libgcc/gthr-default.h \
stamp-${host_alias}
sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
-e 's/\(GCC${uppercase}*_H\)/_GLIBCXX_\1/g' \
-e 's/SUPPORTS_WEAK/__GXX_WEAK__/g' \
-e 's/\(${uppercase}*USE_WEAK\)/_GLIBCXX_\1/g' \
-e 's,^#include "\(.*\)",#include <bits/\1>,g' \
- < ${toplevel_srcdir}/gcc/${glibcxx_thread_h} > $@
+ < $< > $@
# Build two precompiled C++ includes, stdc++.h.gch/*.gch
${pch1a_output}: ${allstamped} ${host_builddir}/c++config.h ${pch1_source}
diff --git a/libstdc++-v3/libsupc++/Makefile.in b/libstdc++-v3/libsupc++/Makefile.in
index 4c36c35e0bc..9ef5e683af8 100644
--- a/libstdc++-v3/libsupc++/Makefile.in
+++ b/libstdc++-v3/libsupc++/Makefile.in
@@ -272,7 +272,6 @@ glibcxx_builddir = @glibcxx_builddir@
glibcxx_localedir = @glibcxx_localedir@
glibcxx_prefixdir = @glibcxx_prefixdir@
glibcxx_srcdir = @glibcxx_srcdir@
-glibcxx_thread_h = @glibcxx_thread_h@
glibcxx_toolexecdir = @glibcxx_toolexecdir@
glibcxx_toolexeclibdir = @glibcxx_toolexeclibdir@
gxx_include_dir = @gxx_include_dir@
@@ -312,6 +311,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+toplevel_builddir = @toplevel_builddir@
toplevel_srcdir = @toplevel_srcdir@
# May be used by various substitution variables.
diff --git a/libstdc++-v3/po/Makefile.in b/libstdc++-v3/po/Makefile.in
index 09092677b04..0226b894a6e 100644
--- a/libstdc++-v3/po/Makefile.in
+++ b/libstdc++-v3/po/Makefile.in
@@ -213,7 +213,6 @@ glibcxx_builddir = @glibcxx_builddir@
glibcxx_localedir = @glibcxx_localedir@
glibcxx_prefixdir = @glibcxx_prefixdir@
glibcxx_srcdir = @glibcxx_srcdir@
-glibcxx_thread_h = @glibcxx_thread_h@
glibcxx_toolexecdir = @glibcxx_toolexecdir@
glibcxx_toolexeclibdir = @glibcxx_toolexeclibdir@
gxx_include_dir = @gxx_include_dir@
@@ -253,6 +252,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+toplevel_builddir = @toplevel_builddir@
toplevel_srcdir = @toplevel_srcdir@
# May be used by various substitution variables.
diff --git a/libstdc++-v3/python/Makefile.in b/libstdc++-v3/python/Makefile.in
index 01bcddbe1c6..ca046cf0a33 100644
--- a/libstdc++-v3/python/Makefile.in
+++ b/libstdc++-v3/python/Makefile.in
@@ -237,7 +237,6 @@ glibcxx_builddir = @glibcxx_builddir@
glibcxx_localedir = @glibcxx_localedir@
glibcxx_prefixdir = @glibcxx_prefixdir@
glibcxx_srcdir = @glibcxx_srcdir@
-glibcxx_thread_h = @glibcxx_thread_h@
glibcxx_toolexecdir = @glibcxx_toolexecdir@
glibcxx_toolexeclibdir = @glibcxx_toolexeclibdir@
gxx_include_dir = @gxx_include_dir@
@@ -277,6 +276,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+toplevel_builddir = @toplevel_builddir@
toplevel_srcdir = @toplevel_srcdir@
# May be used by various substitution variables.
diff --git a/libstdc++-v3/src/Makefile.in b/libstdc++-v3/src/Makefile.in
index 5d31fb20c41..c52e5c4df61 100644
--- a/libstdc++-v3/src/Makefile.in
+++ b/libstdc++-v3/src/Makefile.in
@@ -277,7 +277,6 @@ glibcxx_builddir = @glibcxx_builddir@
glibcxx_localedir = @glibcxx_localedir@
glibcxx_prefixdir = @glibcxx_prefixdir@
glibcxx_srcdir = @glibcxx_srcdir@
-glibcxx_thread_h = @glibcxx_thread_h@
glibcxx_toolexecdir = @glibcxx_toolexecdir@
glibcxx_toolexeclibdir = @glibcxx_toolexeclibdir@
gxx_include_dir = @gxx_include_dir@
@@ -317,6 +316,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+toplevel_builddir = @toplevel_builddir@
toplevel_srcdir = @toplevel_srcdir@
# May be used by various substitution variables.
diff --git a/libstdc++-v3/testsuite/Makefile.in b/libstdc++-v3/testsuite/Makefile.in
index 37e8a3cf675..af161ea5d26 100644
--- a/libstdc++-v3/testsuite/Makefile.in
+++ b/libstdc++-v3/testsuite/Makefile.in
@@ -213,7 +213,6 @@ glibcxx_builddir = @glibcxx_builddir@
glibcxx_localedir = @glibcxx_localedir@
glibcxx_prefixdir = @glibcxx_prefixdir@
glibcxx_srcdir = @glibcxx_srcdir@
-glibcxx_thread_h = @glibcxx_thread_h@
glibcxx_toolexecdir = @glibcxx_toolexecdir@
glibcxx_toolexeclibdir = @glibcxx_toolexeclibdir@
gxx_include_dir = @gxx_include_dir@
@@ -253,6 +252,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+toplevel_builddir = @toplevel_builddir@
toplevel_srcdir = @toplevel_srcdir@
AUTOMAKE_OPTIONS = nostdinc
RUNTESTDEFAULTFLAGS = --tool $$tool --srcdir $$srcdir