aboutsummaryrefslogtreecommitdiff
path: root/gcc/configure
diff options
context:
space:
mode:
authorDave Korn <dave.korn.cygwin@gmail.com>2009-11-30 23:22:04 +0000
committerDave Korn <davek@gcc.gnu.org>2009-11-30 23:22:04 +0000
commitf7e413e2d4d7024c6410c82503cd89d156a1807e (patch)
tree9471c38454c458137ad85815b86a55469917bef7 /gcc/configure
parent9c39ceab1a91f8f95ec0b44e1388832e6f91e0d3 (diff)
downloadgcc-f7e413e2d4d7024c6410c82503cd89d156a1807e.zip
gcc-f7e413e2d4d7024c6410c82503cd89d156a1807e.tar.gz
gcc-f7e413e2d4d7024c6410c82503cd89d156a1807e.tar.bz2
configure.ac (USE_CYGWIN_LIBSTDCXX_WRAPPERS): Define to reflect status of AC_CHECK_FUNC for Cygwin DLL libstdc++ support wrappers.
gcc/ChangeLog: 2009-11-30 Dave Korn <dave.korn.cygwin@gmail.com> * configure.ac (USE_CYGWIN_LIBSTDCXX_WRAPPERS): Define to reflect status of AC_CHECK_FUNC for Cygwin DLL libstdc++ support wrappers. * configure: Regenerate. * config.in: Regenerate. * config/i386/cygwin.h (CXX_WRAP_SPEC_LIST): Define list of --wrap options for Cygwin DLL libstdc++ support wrappers. (CXX_WRAP_SPEC_OPT): Define spec to use wrappers or not by default according to defined value of USE_CYGWIN_LIBSTDCXX_WRAPPERS. (CXX_WRAP_SPEC): Define entire wrapper spec in or out according to whether USE_CYGWIN_LIBSTDCXX_WRAPPERS is even defined or not. (LINK_SPEC): Include CXX_WRAP_SPEC. * gcc/config/i386/winnt.c (wrapper_strcmp): New qsort helper function. (i386_find_on_wrapper_list): Check if a function is found on the list of libstdc++ wrapper options. (i386_pe_file_end): If we are importing a wrapped function, also emit an external declaration for the real version. * config/i386/cygming.opt (muse-libstdc-wrappers): New option for Cygwin targets. Update copyright year. libstdc++-v3/ChangeLog: 2009-11-30 Dave Korn <dave.korn.cygwin@gmail.com> * libstdc++-v3/acinclude.m4 (GLIBCXX_ENABLE_SYMVERS): Don't disable on PE targets. * libstdc++-v3/configure: Regenerate. * libstdc++-v3/configure.host: Add libtool DLL options for Cygwin and MinGW platforms. * libstdc++-v3/include/bits/c++config (_GLIBCXX_VISIBILITY_ATTR): On platforms that don't support visibility, allow them to declare a macro _GLIBCXX_PSEUDO_VISIBILITY that is applied in place of visibility. (_GLIBCXX_PSEUDO_VISIBILITY): Supply empty default if not declared by CPU- or OS-specific headers. * libstdc++-v3/config/os/newlib/os_defines.h (_GLIBCXX_PSEUDO_VISIBILITY_default): New macro for dllimport. (_GLIBCXX_PSEUDO_VISIBILITY_hidden): New empty macro. (_GLIBCXX_PSEUDO_VISIBILITY): Evaluate to one of the above. * libstdc++-v3/config/os/mingw32/os_defines.h (_GLIBCXX_PSEUDO_VISIBILITY_default, _GLIBCXX_PSEUDO_VISIBILITY_hidden, _GLIBCXX_PSEUDO_VISIBILITY): Likewise. From-SVN: r154853
Diffstat (limited to 'gcc/configure')
-rwxr-xr-xgcc/configure26
1 files changed, 26 insertions, 0 deletions
diff --git a/gcc/configure b/gcc/configure
index f49cdb7..abf0b9a 100755
--- a/gcc/configure
+++ b/gcc/configure
@@ -22699,6 +22699,32 @@ fi
i[34567]86-*-* | x86_64-*-*)
case $target_os in
+ cygwin*)
+ # Full C++ conformance when using a shared libstdc++-v3 requires some
+ # support from the Cygwin DLL, which in more recent versions exports
+ # wrappers to aid in interposing and redirecting operators new, delete,
+ # etc., as per n2800 #17.6.4.6 [replacement.functions]. Check if we
+ # are configuring for a version of Cygwin that exports the wrappers.
+ if test x$host = x$target; then
+ ac_fn_c_check_func "$LINENO" "__wrap__Znaj" "ac_cv_func___wrap__Znaj"
+if test "x$ac_cv_func___wrap__Znaj" = x""yes; then :
+ gcc_ac_cygwin_dll_wrappers=yes
+else
+ gcc_ac_cygwin_dll_wrappers=no
+fi
+
+ else
+ # Can't check presence of libc functions during cross-compile, so
+ # we just have to assume we're building for an up-to-date target.
+ gcc_ac_cygwin_dll_wrappers=yes
+ fi
+
+cat >>confdefs.h <<_ACEOF
+#define USE_CYGWIN_LIBSTDCXX_WRAPPERS `if test $gcc_ac_cygwin_dll_wrappers = yes; then echo 1; else echo 0; fi`
+_ACEOF
+
+ esac
+ case $target_os in
cygwin* | pe | mingw32*)
# Recent binutils allows the three-operand form of ".comm" on PE. This
# definition is used unconditionally to initialise the default state of