diff options
author | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-02-20 10:38:10 +0000 |
---|---|---|
committer | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-02-20 10:38:10 +0000 |
commit | e7e5252e5c3c42a01498c3dffe013e71849562af (patch) | |
tree | 6e9302835ec9153549906710a2dc653b3fb1e0b7 /libstdc++-v3 | |
parent | b2ef120cd90a0d02735b3f310274bdfad29429aa (diff) | |
download | gcc-e7e5252e5c3c42a01498c3dffe013e71849562af.tar.gz |
2012-02-20 Basile Starynkevitch <basile@starynkevitch.net>
MELT branch merged with trunk rev 184385 using svnmerge
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@184387 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3')
-rw-r--r-- | libstdc++-v3/ChangeLog | 60 | ||||
-rw-r--r-- | libstdc++-v3/Makefile.in | 5 | ||||
-rw-r--r-- | libstdc++-v3/acinclude.m4 | 118 | ||||
-rwxr-xr-x | libstdc++-v3/configure | 372 | ||||
-rw-r--r-- | libstdc++-v3/configure.ac | 8 | ||||
-rw-r--r-- | libstdc++-v3/doc/Makefile.in | 5 | ||||
-rw-r--r-- | libstdc++-v3/doc/xml/manual/configure.xml | 7 | ||||
-rw-r--r-- | libstdc++-v3/fragment.am | 8 | ||||
-rw-r--r-- | libstdc++-v3/include/Makefile.in | 5 | ||||
-rw-r--r-- | libstdc++-v3/libsupc++/Makefile.in | 5 | ||||
-rw-r--r-- | libstdc++-v3/po/Makefile.in | 5 | ||||
-rw-r--r-- | libstdc++-v3/python/Makefile.am | 6 | ||||
-rw-r--r-- | libstdc++-v3/python/Makefile.in | 8 | ||||
-rw-r--r-- | libstdc++-v3/src/Makefile.in | 5 | ||||
-rw-r--r-- | libstdc++-v3/src/c++11/Makefile.in | 5 | ||||
-rw-r--r-- | libstdc++-v3/src/c++98/Makefile.in | 5 | ||||
-rw-r--r-- | libstdc++-v3/src/c++98/locale.cc | 2 | ||||
-rw-r--r-- | libstdc++-v3/testsuite/Makefile.in | 5 |
18 files changed, 460 insertions, 174 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 8510625e7ce..34fd1410cd7 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,61 @@ +2012-02-17 Benjamin Kosnik <bkoz@redhat.com> + + PR libstdc++/51798 continued. + * acinclude.m4 (GLIBCXX_ENABLE_ATOMIC_BUILTINS): Grep for + __atomic_, not __sync. + * configure: Regenerated. + +2012-02-17 Benjamin Kosnik <bkoz@redhat.com> + + PR libstdc++/47058 + * acinclude.m4 (GLIBCXX_ENABLE_WERROR): New. + (GLIBCXX_EXPORT_FLAGS): Add -Wabi to WARN_FLAGS + * configure.ac: Use it. + * fragment.am: Set WERROR_FLAG conditionally on --disable-werror. + * configure: Regenerate. + * python/Makefile.in: Same. + * Makefile.in: Same. + * doc/Makefile.in: Same. + * include/Makefile.in: Same. + * po/Makefile.in: Same. + * python/Makefile.in: Same. + * src/Makefile.in: Same. + * src/c++11/Makefile.in: Same. + * src/c++98/Makefile.in: Same. + * testsuite/Makefile.in: Same. + +2012-02-17 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> + + PR libstdc++/52189 + * acinclude.m4 (GLIBCXX_CHECK_GTHREADS): Handle + --enable-libstdcxx-threads. + Disable on Solaris 8/9 with symbol versioning. + * configure.ac (GLIBCXX_CHECK_GTHREADS): Move after + GLIBCXX_ENABLE_SYMVERS. + * configure: Regenerate. + * doc/xml/manual/configure.xml (--enable-libstdcxx-threads): Explain. + +2012-02-15 DJ Delorie <dj@redhat.com> + + * src/c++98/locale.cc (locale::facet::_S_get_c_locale): Fix typo. + +2012-02-15 Benjamin Kosnik <bkoz@redhat.com> + + PR libstdc++/51368 + * acinclude.m4 (GLIBCXX_ENABLE_PYTHON): New. + * configure.ac: Use it. + * python/Makefile.am: Same. + * configure: Regenerate. + * python/Makefile.in: Regenerate. + * Makefile.in: Same. + * doc/Makefile.in: Same. + * include/Makefile.in: Same. + * po/Makefile.in: Same. + * src/Makefile.in: Same. + * src/c++11/Makefile.in: Same. + * src/c++98/Makefile.in: Same. + * testsuite/Makefile.in: Same. + 2012-02-14 Jonathan Wakely <jwakely.gcc@gmail.com> * 30_threads/thread/native_handle/typesizes.cc: Do not run on cygwin. @@ -30,7 +88,7 @@ * libsupc++/guard.cc (__cxa_guard_acquire): Same. 2012-02-10 Benjamin Kosnik <bkoz@redhat.com> - Jonathan Wakely <jwakely.gcc@gmail.com> + Jonathan Wakely <jwakely.gcc@gmail.com> PR libstdc++/51798 continued. * acinclude.m4 (GLIBCXX_ENABLE_ATOMIC_BUILTINS): Use __atomic_* diff --git a/libstdc++-v3/Makefile.in b/libstdc++-v3/Makefile.in index a6b15e2f312..94ec3e9080d 100644 --- a/libstdc++-v3/Makefile.in +++ b/libstdc++-v3/Makefile.in @@ -264,6 +264,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -287,6 +288,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -294,7 +297,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4 index e089b20dd4f..b832527ef28 100644 --- a/libstdc++-v3/acinclude.m4 +++ b/libstdc++-v3/acinclude.m4 @@ -729,7 +729,7 @@ AC_DEFUN([GLIBCXX_EXPORT_FLAGS], [ # OPTIMIZE_CXXFLAGS = -O3 -fstrict-aliasing -fvtable-gc AC_SUBST(OPTIMIZE_CXXFLAGS) - WARN_FLAGS='-Wall -Wextra -Wwrite-strings -Wcast-qual' + WARN_FLAGS='-Wall -Wextra -Wwrite-strings -Wcast-qual -Wabi' AC_SUBST(WARN_FLAGS) ]) @@ -1737,26 +1737,26 @@ AC_DEFUN([GLIBCXX_CHECK_MATH_PROTO], [ { return __builtin_fabsf(__x); } } ])], - [glibcxx_cv_abs_float=no], - [glibcxx_cv_abs_float=yes] + [glibcxx_cv_abs_float=no], + [glibcxx_cv_abs_float=yes] )]) # autoheader cannot handle indented templates. AH_VERBATIM([__CORRECT_ISO_CPP_MATH_H_PROTO1], - [/* Define if all C++ overloads are available in <math.h>. */ + [/* Define if all C++ overloads are available in <math.h>. */ #if __cplusplus >= 199711L #undef __CORRECT_ISO_CPP_MATH_H_PROTO1 #endif]) AH_VERBATIM([__CORRECT_ISO_CPP_MATH_H_PROTO2], - [/* Define if only double std::abs(double) is available in <math.h>. */ + [/* Define if only double std::abs(double) is available in <math.h>. */ #if __cplusplus >= 199711L #undef __CORRECT_ISO_CPP_MATH_H_PROTO2 #endif]) if test $glibcxx_cv_abs_float = yes; then - AC_DEFINE(__CORRECT_ISO_CPP_MATH_H_PROTO1) + AC_DEFINE(__CORRECT_ISO_CPP_MATH_H_PROTO1) else - AC_DEFINE(__CORRECT_ISO_CPP_MATH_H_PROTO2) + AC_DEFINE(__CORRECT_ISO_CPP_MATH_H_PROTO2) fi AC_MSG_RESULT($glibcxx_cv_abs_float) ;; @@ -1787,19 +1787,19 @@ AC_DEFUN([GLIBCXX_CHECK_STDLIB_PROTO], [ inline long abs(long __i) { return labs(__i); } } - ])], - [glibcxx_cv_abs_long=no], - [glibcxx_cv_abs_long=yes] + ])], + [glibcxx_cv_abs_long=no], + [glibcxx_cv_abs_long=yes] )]) # autoheader cannot handle indented templates. AH_VERBATIM([__CORRECT_ISO_CPP_STDLIB_H_PROTO], - [/* Define if all C++ overloads are available in <stdlib.h>. */ + [/* Define if all C++ overloads are available in <stdlib.h>. */ #if __cplusplus >= 199711L #undef __CORRECT_ISO_CPP_STDLIB_H_PROTO #endif]) if test $glibcxx_cv_abs_long = yes; then - AC_DEFINE(__CORRECT_ISO_CPP_STDLIB_H_PROTO, 1) + AC_DEFINE(__CORRECT_ISO_CPP_STDLIB_H_PROTO, 1) fi AC_MSG_RESULT($glibcxx_cv_abs_long) ;; @@ -2495,7 +2495,7 @@ template<typename T> int main() { - typename same<double, __float128>::type f1; + typename same<double, __float128>::type f1; typename same<long double, __float128>::type f2; } EOF @@ -2729,7 +2729,7 @@ AC_DEFUN([GLIBCXX_ENABLE_ATOMIC_BUILTINS], [ atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); ], @@ -2748,7 +2748,7 @@ AC_DEFUN([GLIBCXX_ENABLE_ATOMIC_BUILTINS], [ atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); ], @@ -2767,7 +2767,7 @@ AC_DEFUN([GLIBCXX_ENABLE_ATOMIC_BUILTINS], [ atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); ], @@ -2786,7 +2786,7 @@ AC_DEFUN([GLIBCXX_ENABLE_ATOMIC_BUILTINS], [ atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); ], @@ -2814,17 +2814,17 @@ int main() atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); - + return 0; } EOF AC_MSG_CHECKING([for atomic builtins for bool]) if AC_TRY_EVAL(ac_compile); then - if grep __sync_ conftest.s >/dev/null 2>&1 ; then + if grep __atomic_ conftest.s >/dev/null 2>&1 ; then glibcxx_cv_atomic_bool=no else glibcxx_cv_atomic_bool=yes @@ -2843,7 +2843,7 @@ int main() atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -2853,7 +2853,7 @@ EOF AC_MSG_CHECKING([for atomic builtins for short]) if AC_TRY_EVAL(ac_compile); then - if grep __sync_ conftest.s >/dev/null 2>&1 ; then + if grep __atomic_ conftest.s >/dev/null 2>&1 ; then glibcxx_cv_atomic_short=no else glibcxx_cv_atomic_short=yes @@ -2873,7 +2873,7 @@ int main() atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -2883,7 +2883,7 @@ EOF AC_MSG_CHECKING([for atomic builtins for int]) if AC_TRY_EVAL(ac_compile); then - if grep __sync_ conftest.s >/dev/null 2>&1 ; then + if grep __atomic_ conftest.s >/dev/null 2>&1 ; then glibcxx_cv_atomic_int=no else glibcxx_cv_atomic_int=yes @@ -2902,7 +2902,7 @@ int main() atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -2912,7 +2912,7 @@ EOF AC_MSG_CHECKING([for atomic builtins for long long]) if AC_TRY_EVAL(ac_compile); then - if grep __sync_ conftest.s >/dev/null 2>&1 ; then + if grep __atomic_ conftest.s >/dev/null 2>&1 ; then glibcxx_cv_atomic_long_long=no else glibcxx_cv_atomic_long_long=yes @@ -3328,7 +3328,14 @@ dnl Check if gthread implementation defines the types and functions dnl required by the c++0x thread library. Conforming gthread dnl implementations can define __GTHREADS_CXX0X to enable use with c++0x. dnl +dnl GLIBCXX_ENABLE_SYMVERS must be done before this. +dnl AC_DEFUN([GLIBCXX_CHECK_GTHREADS], [ + GLIBCXX_ENABLE(libstdcxx-threads,auto,,[enable C++11 threads support]) + + if test x$enable_libstdcxx_threads = xauto || + test x$enable_libstdcxx_threads = xyes; then + AC_LANG_SAVE AC_LANG_CPLUSPLUS @@ -3348,13 +3355,13 @@ AC_DEFUN([GLIBCXX_CHECK_GTHREADS], [ [ // In case of POSIX threads check _POSIX_TIMEOUTS. #if (defined(_PTHREADS) \ - && (!defined(_POSIX_TIMEOUTS) || _POSIX_TIMEOUTS <= 0)) + && (!defined(_POSIX_TIMEOUTS) || _POSIX_TIMEOUTS <= 0)) #error #endif ], [ac_gthread_use_mutex_timedlock=1], [ac_gthread_use_mutex_timedlock=0]) AC_DEFINE_UNQUOTED(_GTHREAD_USE_MUTEX_TIMEDLOCK, $ac_gthread_use_mutex_timedlock, - [Define to 1 if mutex_timedlock is available.]) + [Define to 1 if mutex_timedlock is available.]) if test $ac_gthread_use_mutex_timedlock = 1 ; then res_mutex_timedlock=yes ; else res_mutex_timedlock=no ; fi @@ -3367,7 +3374,28 @@ AC_DEFUN([GLIBCXX_CHECK_GTHREADS], [ #ifndef __GTHREADS_CXX0X #error #endif - ], [ac_has_gthreads=yes], [ac_has_gthreads=no]) + ], [case $target_os in + # gthreads support breaks symbol versioning on Solaris 8/9 (PR + # libstdc++/52189). + solaris2.[[89]]*) + if test x$enable_symvers = xno; then + ac_has_gthreads=yes + elif test x$enable_libstdcxx_threads = xyes; then + AC_MSG_WARN([You have requested C++11 threads support, but]) + AC_MSG_WARN([this breaks symbol versioning.]) + ac_has_gthreads=yes + else + ac_has_gthreads=no + fi + ;; + *) + ac_has_gthreads=yes + ;; + esac], + [ac_has_gthreads=no]) + else + ac_has_gthreads=no + fi AC_MSG_RESULT([$ac_has_gthreads]) @@ -3543,6 +3571,38 @@ AC_DEFUN([GLIBCXX_CHECK_SYSCTL_HW_NCPU], [ AC_LANG_RESTORE ]) +dnl +dnl Check to see if python pretty printing can be activated. +dnl +dnl --with-python-dir=dir +dnl installs directory into $prefix/dir +AC_DEFUN([GLIBCXX_ENABLE_PYTHON], [ + +AC_MSG_CHECKING([for custom python install directory]) +AC_ARG_WITH([python-dir], + AS_HELP_STRING([--with-python-dir], + [the location to install Python modules. This path is relative starting from the prefix.]), + [with_python_dir=$withval], [with_python_dir="no"]) +AC_MSG_RESULT(${with_python_dir}) + +# Needed for installing Python modules during make install. +python_mod_dir="${with_python_dir}" +AC_SUBST(python_mod_dir) +GLIBCXX_CONDITIONAL(ENABLE_PYTHONDIR, test $python_mod_dir != no) +]) + +dnl +dnl Check to see if -Werror is disabled. +dnl +dnl --enable-werror/--disable-werror +AC_DEFUN([GLIBCXX_ENABLE_WERROR], [ + AC_MSG_CHECKING([for -Werror]) + GLIBCXX_ENABLE(werror,$1,,[turns on -Werror]) + AC_MSG_RESULT($enable_werror) + GLIBCXX_CONDITIONAL(ENABLE_WERROR, test $enable_werror = yes) +]) + + # Macros from the top-level gcc directory. m4_include([../config/gc++filt.m4]) m4_include([../config/tls.m4]) diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure index 4755149c731..04ac0793358 100755 --- a/libstdc++-v3/configure +++ b/libstdc++-v3/configure @@ -664,6 +664,11 @@ LIBICONV OPT_LDFLAGS SECTION_LDFLAGS GLIBCXX_LIBS +ENABLE_WERROR_FALSE +ENABLE_WERROR_TRUE +ENABLE_PYTHONDIR_FALSE +ENABLE_PYTHONDIR_TRUE +python_mod_dir ENABLE_EXTERN_TEMPLATE_FALSE ENABLE_EXTERN_TEMPLATE_TRUE EXTRA_CXX_FLAGS @@ -856,6 +861,8 @@ enable_libstdcxx_debug enable_cxx_flags enable_fully_dynamic_string enable_extern_template +with_python_dir +enable_werror enable_libstdcxx_time enable_tls enable_rpath @@ -864,6 +871,7 @@ with_system_libunwind enable_linux_futex enable_symvers enable_libstdcxx_visibility +enable_libstdcxx_threads with_gxx_include_dir enable_version_specific_runtime_libs ' @@ -1544,6 +1552,7 @@ Optional Features: memory [default=no] --enable-extern-template enable extern template [default=yes] + --enable-werror turns on -Werror [default=yes] --enable-libstdcxx-time[=KIND] use KIND for check type [default=no] --enable-tls Use thread-local storage [default=yes] @@ -1554,6 +1563,8 @@ Optional Features: [default=yes] --enable-libstdcxx-visibility enables visibility safe usage [default=yes] + --enable-libstdcxx-threads + enable C++11 threads support [default=auto] --enable-version-specific-runtime-libs Specify that runtime libraries should be installed in a compiler-specific directory @@ -1568,6 +1579,8 @@ Optional Packages: --with-pic try to use only PIC/non-PIC objects [default=use both] --with-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-python-dir the location to install Python modules. This path is + relative starting from the prefix. --with-gnu-ld assume the C compiler uses GNU ld default=no --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib --without-libiconv-prefix don't search for libiconv in includedir and libdir @@ -11486,7 +11499,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11489 "configure" +#line 11502 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -11592,7 +11605,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11595 "configure" +#line 11608 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -14950,7 +14963,7 @@ fi # # Fake what AC_TRY_COMPILE does. XXX Look at redoing this new-style. cat > conftest.$ac_ext << EOF -#line 14953 "configure" +#line 14966 "configure" struct S { ~S(); }; void bar(); void foo() @@ -15128,7 +15141,7 @@ typedef bool atomic_type; atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -15170,7 +15183,7 @@ typedef short atomic_type; atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -15212,7 +15225,7 @@ typedef int atomic_type; atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -15254,7 +15267,7 @@ typedef long long atomic_type; atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -15285,7 +15298,7 @@ $as_echo "$glibcxx_cv_atomic_long_long" >&6; } # Fake what AC_TRY_COMPILE does. cat > conftest.$ac_ext << EOF -#line 15288 "configure" +#line 15301 "configure" int main() { typedef bool atomic_type; @@ -15294,7 +15307,7 @@ int main() atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -15309,7 +15322,7 @@ $as_echo_n "checking for atomic builtins for bool... " >&6; } ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - if grep __sync_ conftest.s >/dev/null 2>&1 ; then + if grep __atomic_ conftest.s >/dev/null 2>&1 ; then glibcxx_cv_atomic_bool=no else glibcxx_cv_atomic_bool=yes @@ -15320,7 +15333,7 @@ $as_echo "$glibcxx_cv_atomic_bool" >&6; } rm -f conftest* cat > conftest.$ac_ext << EOF -#line 15323 "configure" +#line 15336 "configure" int main() { typedef short atomic_type; @@ -15329,7 +15342,7 @@ int main() atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -15344,7 +15357,7 @@ $as_echo_n "checking for atomic builtins for short... " >&6; } ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - if grep __sync_ conftest.s >/dev/null 2>&1 ; then + if grep __atomic_ conftest.s >/dev/null 2>&1 ; then glibcxx_cv_atomic_short=no else glibcxx_cv_atomic_short=yes @@ -15355,7 +15368,7 @@ $as_echo "$glibcxx_cv_atomic_short" >&6; } rm -f conftest* cat > conftest.$ac_ext << EOF -#line 15358 "configure" +#line 15371 "configure" int main() { // NB: _Atomic_word not necessarily int. @@ -15365,7 +15378,7 @@ int main() atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -15380,7 +15393,7 @@ $as_echo_n "checking for atomic builtins for int... " >&6; } ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - if grep __sync_ conftest.s >/dev/null 2>&1 ; then + if grep __atomic_ conftest.s >/dev/null 2>&1 ; then glibcxx_cv_atomic_int=no else glibcxx_cv_atomic_int=yes @@ -15391,7 +15404,7 @@ $as_echo "$glibcxx_cv_atomic_int" >&6; } rm -f conftest* cat > conftest.$ac_ext << EOF -#line 15394 "configure" +#line 15407 "configure" int main() { typedef long long atomic_type; @@ -15400,7 +15413,7 @@ int main() atomic_type c3(0); __atomic_fetch_add(&c1, c2, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&c1, &c2, c3, true, __ATOMIC_ACQ_REL, - __ATOMIC_RELAXED); + __ATOMIC_RELAXED); __atomic_test_and_set(&c1, __ATOMIC_RELAXED); __atomic_load_n(&c1, __ATOMIC_RELAXED); @@ -15415,7 +15428,7 @@ $as_echo_n "checking for atomic builtins for long long... " >&6; } ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - if grep __sync_ conftest.s >/dev/null 2>&1 ; then + if grep __atomic_ conftest.s >/dev/null 2>&1 ; then glibcxx_cv_atomic_long_long=no else glibcxx_cv_atomic_long_long=yes @@ -15471,7 +15484,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 15474 "configure" +#line 15487 "configure" int main() { _Decimal32 d1; @@ -15513,7 +15526,7 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu # unnecessary for this test. cat > conftest.$ac_ext << EOF -#line 15516 "configure" +#line 15529 "configure" template<typename T1, typename T2> struct same { typedef T2 type; }; @@ -15547,7 +15560,7 @@ $as_echo "$enable_int128" >&6; } rm -f conftest* cat > conftest.$ac_ext << EOF -#line 15550 "configure" +#line 15563 "configure" template<typename T1, typename T2> struct same { typedef T2 type; }; @@ -17240,6 +17253,46 @@ $as_echo "$enable_extern_template" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for custom python install directory" >&5 +$as_echo_n "checking for custom python install directory... " >&6; } + +# Check whether --with-python-dir was given. +if test "${with_python_dir+set}" = set; then : + withval=$with_python_dir; with_python_dir=$withval +else + with_python_dir="no" +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_python_dir}" >&5 +$as_echo "${with_python_dir}" >&6; } + +# Needed for installing Python modules during make install. +python_mod_dir="${with_python_dir}" + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Werror" >&5 +$as_echo_n "checking for -Werror... " >&6; } + # Check whether --enable-werror was given. +if test "${enable_werror+set}" = set; then : + enableval=$enable_werror; + case "$enableval" in + yes|no) ;; + *) as_fn_error "Argument to enable/disable werror must be yes or no" "$LINENO" 5 ;; + esac + +else + enable_werror=yes +fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_werror" >&5 +$as_echo "$enable_werror" >&6; } + + + # Checks for operating systems support that doesn't require linking. @@ -17286,10 +17339,10 @@ fi if test $glibcxx_cv_abs_float = yes; then - $as_echo "#define __CORRECT_ISO_CPP_MATH_H_PROTO1 1" >>confdefs.h + $as_echo "#define __CORRECT_ISO_CPP_MATH_H_PROTO1 1" >>confdefs.h else - $as_echo "#define __CORRECT_ISO_CPP_MATH_H_PROTO2 1" >>confdefs.h + $as_echo "#define __CORRECT_ISO_CPP_MATH_H_PROTO2 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $glibcxx_cv_abs_float" >&5 @@ -17347,7 +17400,7 @@ fi # autoheader cannot handle indented templates. if test $glibcxx_cv_abs_long = yes; then - $as_echo "#define __CORRECT_ISO_CPP_STDLIB_H_PROTO 1" >>confdefs.h + $as_echo "#define __CORRECT_ISO_CPP_STDLIB_H_PROTO 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $glibcxx_cv_abs_long" >&5 @@ -19790,107 +19843,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu -# For gthread support - - - ac_ext=cpp -ac_cpp='$CXXCPP $CPPFLAGS' -ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu - - - ac_save_CXXFLAGS="$CXXFLAGS" - 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 - posix) - CXXFLAGS="$CXXFLAGS -DSUPPORTS_WEAK -DGTHREAD_USE_WEAK -D_PTHREADS" - esac - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it can be safely assumed that mutex_timedlock is available" >&5 -$as_echo_n "checking whether it can be safely assumed that mutex_timedlock is available... " >&6; } - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <unistd.h> -int -main () -{ - - // In case of POSIX threads check _POSIX_TIMEOUTS. - #if (defined(_PTHREADS) \ - && (!defined(_POSIX_TIMEOUTS) || _POSIX_TIMEOUTS <= 0)) - #error - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : - ac_gthread_use_mutex_timedlock=1 -else - ac_gthread_use_mutex_timedlock=0 -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - - -cat >>confdefs.h <<_ACEOF -#define _GTHREAD_USE_MUTEX_TIMEDLOCK $ac_gthread_use_mutex_timedlock -_ACEOF - - - if test $ac_gthread_use_mutex_timedlock = 1 ; then res_mutex_timedlock=yes ; - else res_mutex_timedlock=no ; fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $res_mutex_timedlock" >&5 -$as_echo "$res_mutex_timedlock" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gthreads library" >&5 -$as_echo_n "checking for gthreads library... " >&6; } - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include "gthr.h" -int -main () -{ - - #ifndef __GTHREADS_CXX0X - #error - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : - ac_has_gthreads=yes -else - ac_has_gthreads=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_has_gthreads" >&5 -$as_echo "$ac_has_gthreads" >&6; } - - if test x"$ac_has_gthreads" = x"yes"; then - -$as_echo "#define _GLIBCXX_HAS_GTHREADS 1" >>confdefs.h - - fi - - CXXFLAGS="$ac_save_CXXFLAGS" - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - ac_fn_c_check_header_mongrel "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default" if test "x$ac_cv_header_locale_h" = x""yes; then : @@ -65530,6 +65482,146 @@ done +# For gthread support. Depends on GLIBCXX_ENABLE_SYMVERS. + + # Check whether --enable-libstdcxx-threads was given. +if test "${enable_libstdcxx_threads+set}" = set; then : + enableval=$enable_libstdcxx_threads; + case "$enableval" in + yes|no) ;; + *) as_fn_error "Argument to enable/disable libstdcxx-threads must be yes or no" "$LINENO" 5 ;; + esac + +else + enable_libstdcxx_threads=auto +fi + + + + if test x$enable_libstdcxx_threads = xauto || + test x$enable_libstdcxx_threads = xyes; then + + + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + + ac_save_CXXFLAGS="$CXXFLAGS" + 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 + posix) + CXXFLAGS="$CXXFLAGS -DSUPPORTS_WEAK -DGTHREAD_USE_WEAK -D_PTHREADS" + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it can be safely assumed that mutex_timedlock is available" >&5 +$as_echo_n "checking whether it can be safely assumed that mutex_timedlock is available... " >&6; } + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <unistd.h> +int +main () +{ + + // In case of POSIX threads check _POSIX_TIMEOUTS. + #if (defined(_PTHREADS) \ + && (!defined(_POSIX_TIMEOUTS) || _POSIX_TIMEOUTS <= 0)) + #error + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_gthread_use_mutex_timedlock=1 +else + ac_gthread_use_mutex_timedlock=0 +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + +cat >>confdefs.h <<_ACEOF +#define _GTHREAD_USE_MUTEX_TIMEDLOCK $ac_gthread_use_mutex_timedlock +_ACEOF + + + if test $ac_gthread_use_mutex_timedlock = 1 ; then res_mutex_timedlock=yes ; + else res_mutex_timedlock=no ; fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $res_mutex_timedlock" >&5 +$as_echo "$res_mutex_timedlock" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gthreads library" >&5 +$as_echo_n "checking for gthreads library... " >&6; } + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include "gthr.h" +int +main () +{ + + #ifndef __GTHREADS_CXX0X + #error + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + case $target_os in + # gthreads support breaks symbol versioning on Solaris 8/9 (PR + # libstdc++/52189). + solaris2.[89]*) + if test x$enable_symvers = xno; then + ac_has_gthreads=yes + elif test x$enable_libstdcxx_threads = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: You have requested C++11 threads support, but" >&5 +$as_echo "$as_me: WARNING: You have requested C++11 threads support, but" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: this breaks symbol versioning." >&5 +$as_echo "$as_me: WARNING: this breaks symbol versioning." >&2;} + ac_has_gthreads=yes + else + ac_has_gthreads=no + fi + ;; + *) + ac_has_gthreads=yes + ;; + esac +else + ac_has_gthreads=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + else + ac_has_gthreads=no + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_has_gthreads" >&5 +$as_echo "$ac_has_gthreads" >&6; } + + if test x"$ac_has_gthreads" = x"yes"; then + +$as_echo "#define _GLIBCXX_HAS_GTHREADS 1" >>confdefs.h + + fi + + CXXFLAGS="$ac_save_CXXFLAGS" + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + # Define documentation rules conditionally. # See if makeinfo has been installed and is modern enough @@ -66046,6 +66138,24 @@ else fi + if test $python_mod_dir != no; then + ENABLE_PYTHONDIR_TRUE= + ENABLE_PYTHONDIR_FALSE='#' +else + ENABLE_PYTHONDIR_TRUE='#' + ENABLE_PYTHONDIR_FALSE= +fi + + + if test $enable_werror = yes; then + ENABLE_WERROR_TRUE= + ENABLE_WERROR_FALSE='#' +else + ENABLE_WERROR_TRUE='#' + ENABLE_WERROR_FALSE= +fi + + if test $enable_symvers != no; then ENABLE_SYMVERS_TRUE= ENABLE_SYMVERS_FALSE='#' @@ -66322,7 +66432,7 @@ $as_echo "$gxx_include_dir" >&6; } # OPTIMIZE_CXXFLAGS = -O3 -fstrict-aliasing -fvtable-gc - WARN_FLAGS='-Wall -Wextra -Wwrite-strings -Wcast-qual' + WARN_FLAGS='-Wall -Wextra -Wwrite-strings -Wcast-qual -Wabi' @@ -66499,6 +66609,14 @@ if test -z "${ENABLE_EXTERN_TEMPLATE_TRUE}" && test -z "${ENABLE_EXTERN_TEMPLATE as_fn_error "conditional \"ENABLE_EXTERN_TEMPLATE\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${ENABLE_PYTHONDIR_TRUE}" && test -z "${ENABLE_PYTHONDIR_FALSE}"; then + as_fn_error "conditional \"ENABLE_PYTHONDIR\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${ENABLE_WERROR_TRUE}" && test -z "${ENABLE_WERROR_FALSE}"; then + as_fn_error "conditional \"ENABLE_WERROR\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi if test -z "${ENABLE_SYMVERS_TRUE}" && test -z "${ENABLE_SYMVERS_FALSE}"; then as_fn_error "conditional \"ENABLE_SYMVERS\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac index 7607e5b732e..49de141be7b 100644 --- a/libstdc++-v3/configure.ac +++ b/libstdc++-v3/configure.ac @@ -130,6 +130,8 @@ GLIBCXX_ENABLE_PARALLEL([yes]) GLIBCXX_ENABLE_CXX_FLAGS GLIBCXX_ENABLE_FULLY_DYNAMIC_STRING([no]) GLIBCXX_ENABLE_EXTERN_TEMPLATE([yes]) +GLIBCXX_ENABLE_PYTHON +GLIBCXX_ENABLE_WERROR([yes]) # Checks for operating systems support that doesn't require linking. GLIBCXX_CHECK_MATH_PROTO @@ -164,9 +166,6 @@ GLIBCXX_CHECK_GETTIMEOFDAY # NB: The default is [no], because otherwise it requires linking. GLIBCXX_ENABLE_LIBSTDCXX_TIME([no]) -# For gthread support -GLIBCXX_CHECK_GTHREADS - AC_LC_MESSAGES # For hardware_concurrency @@ -335,6 +334,9 @@ GLIBCXX_CONDITIONAL(GLIBCXX_LDBL_COMPAT, test $ac_ldbl_compat = yes) # This depends on GLIBCXX_ENABLE_SYMVERS and GLIBCXX_IS_NATIVE. GLIBCXX_CONFIGURE_TESTSUITE +# For gthread support. Depends on GLIBCXX_ENABLE_SYMVERS. +GLIBCXX_CHECK_GTHREADS + # Define documentation rules conditionally. # See if makeinfo has been installed and is modern enough diff --git a/libstdc++-v3/doc/Makefile.in b/libstdc++-v3/doc/Makefile.in index 2aafe215825..f06084ed186 100644 --- a/libstdc++-v3/doc/Makefile.in +++ b/libstdc++-v3/doc/Makefile.in @@ -248,6 +248,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -271,6 +272,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -278,7 +281,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. diff --git a/libstdc++-v3/doc/xml/manual/configure.xml b/libstdc++-v3/doc/xml/manual/configure.xml index 026711eefab..727d886d316 100644 --- a/libstdc++-v3/doc/xml/manual/configure.xml +++ b/libstdc++-v3/doc/xml/manual/configure.xml @@ -161,6 +161,13 @@ </para> </listitem></varlistentry> + <varlistentry><term><code>--enable-libstdcxx-threads</code></term> + <listitem><para>Enable C++11 threads support. If not explicitly specified, + the configure process enables it if possible. It defaults to 'off' + on Solaris 8 and 9, where it would break symbol versioning. This + option can change the library ABI. + </para> + </listitem></varlistentry> <varlistentry><term><code>--enable-libstdcxx-time</code></term> <listitem><para>This is an abbreviated form of diff --git a/libstdc++-v3/fragment.am b/libstdc++-v3/fragment.am index 2bcbc1ab3d3..304d39637d9 100644 --- a/libstdc++-v3/fragment.am +++ b/libstdc++-v3/fragment.am @@ -13,12 +13,18 @@ STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +if ENABLE_WERROR +WERROR_FLAG=$(WERROR) +else +WERROR_FLAG= +endif + # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. AM_CPPFLAGS = $(GLIBCXX_INCLUDES) diff --git a/libstdc++-v3/include/Makefile.in b/libstdc++-v3/include/Makefile.in index b6f71c54b0b..d13a2732c7d 100644 --- a/libstdc++-v3/include/Makefile.in +++ b/libstdc++-v3/include/Makefile.in @@ -238,6 +238,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -261,6 +262,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -268,7 +271,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. diff --git a/libstdc++-v3/libsupc++/Makefile.in b/libstdc++-v3/libsupc++/Makefile.in index 1153530a8c1..a77f8de57fa 100644 --- a/libstdc++-v3/libsupc++/Makefile.in +++ b/libstdc++-v3/libsupc++/Makefile.in @@ -304,6 +304,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -327,6 +328,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -334,7 +337,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. diff --git a/libstdc++-v3/po/Makefile.in b/libstdc++-v3/po/Makefile.in index f4cfa0eecbe..50b7c961372 100644 --- a/libstdc++-v3/po/Makefile.in +++ b/libstdc++-v3/po/Makefile.in @@ -238,6 +238,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -261,6 +262,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -268,7 +271,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. diff --git a/libstdc++-v3/python/Makefile.am b/libstdc++-v3/python/Makefile.am index 457e45ba46d..49d8f86ac23 100644 --- a/libstdc++-v3/python/Makefile.am +++ b/libstdc++-v3/python/Makefile.am @@ -1,6 +1,6 @@ ## Makefile for the python subdirectory of the GNU C++ Standard library. ## -## Copyright (C) 2009 Free Software Foundation, Inc. +## Copyright (C) 2009, 2012 Free Software Foundation, Inc. ## ## This file is part of the libstdc++ version 3 distribution. ## Process this file with automake to produce Makefile.in. @@ -24,7 +24,11 @@ include $(top_srcdir)/fragment.am ## Where to install the module code. +if ENABLE_PYTHONDIR +pythondir = $(prefix)/$(python_mod_dir) +else pythondir = $(datadir)/gcc-$(gcc_version)/python +endif all-local: gdb.py diff --git a/libstdc++-v3/python/Makefile.in b/libstdc++-v3/python/Makefile.in index d2f8ecd471a..bbe8e936f7b 100644 --- a/libstdc++-v3/python/Makefile.in +++ b/libstdc++-v3/python/Makefile.in @@ -268,6 +268,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -291,6 +292,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -298,12 +301,13 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. AM_CPPFLAGS = $(GLIBCXX_INCLUDES) -pythondir = $(datadir)/gcc-$(gcc_version)/python +@ENABLE_PYTHONDIR_FALSE@pythondir = $(datadir)/gcc-$(gcc_version)/python +@ENABLE_PYTHONDIR_TRUE@pythondir = $(prefix)/$(python_mod_dir) nobase_python_DATA = \ libstdcxx/v6/printers.py \ libstdcxx/v6/__init__.py \ diff --git a/libstdc++-v3/src/Makefile.in b/libstdc++-v3/src/Makefile.in index da74cb69b71..5ffeb3aac99 100644 --- a/libstdc++-v3/src/Makefile.in +++ b/libstdc++-v3/src/Makefile.in @@ -295,6 +295,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -318,6 +319,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -325,7 +328,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. diff --git a/libstdc++-v3/src/c++11/Makefile.in b/libstdc++-v3/src/c++11/Makefile.in index 360cba44554..ba269a3ae0b 100644 --- a/libstdc++-v3/src/c++11/Makefile.in +++ b/libstdc++-v3/src/c++11/Makefile.in @@ -256,6 +256,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -279,6 +280,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -286,7 +289,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. diff --git a/libstdc++-v3/src/c++98/Makefile.in b/libstdc++-v3/src/c++98/Makefile.in index 58e93cdf9d9..1cd42daf313 100644 --- a/libstdc++-v3/src/c++98/Makefile.in +++ b/libstdc++-v3/src/c++98/Makefile.in @@ -275,6 +275,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -298,6 +299,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -305,7 +308,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. diff --git a/libstdc++-v3/src/c++98/locale.cc b/libstdc++-v3/src/c++98/locale.cc index 09dccf0d7d3..8fd487394e1 100644 --- a/libstdc++-v3/src/c++98/locale.cc +++ b/libstdc++-v3/src/c++98/locale.cc @@ -206,7 +206,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION __c_locale locale::facet::_S_get_c_locale() { -#ifdef __GHTREADS +#ifdef __GTHREADS if (__gthread_active_p()) __gthread_once(&_S_once, _S_initialize_once); else diff --git a/libstdc++-v3/testsuite/Makefile.in b/libstdc++-v3/testsuite/Makefile.in index 5520cf017b3..0d7cf167558 100644 --- a/libstdc++-v3/testsuite/Makefile.in +++ b/libstdc++-v3/testsuite/Makefile.in @@ -238,6 +238,7 @@ port_specific_symbol_files = @port_specific_symbol_files@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +python_mod_dir = @python_mod_dir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -264,6 +265,8 @@ PWD_COMMAND = $${PWDCMD-pwd} STAMP = echo timestamp > toolexecdir = $(glibcxx_toolexecdir) toolexeclibdir = $(glibcxx_toolexeclibdir) +@ENABLE_WERROR_FALSE@WERROR_FLAG = +@ENABLE_WERROR_TRUE@WERROR_FLAG = $(WERROR) # These bits are all figured out from configure. Look in acinclude.m4 # or configure.ac to see how they are set. See GLIBCXX_EXPORT_FLAGS. @@ -271,7 +274,7 @@ CONFIG_CXXFLAGS = \ $(SECTION_FLAGS) $(EXTRA_CXX_FLAGS) -frandom-seed=$@ WARN_CXXFLAGS = \ - $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once -Wabi + $(WARN_FLAGS) $(WERROR_FLAG) -fdiagnostics-show-location=once # -I/-D flags to pass when compiling. |