summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorunknown <svoj@mysql.com>2005-06-19 21:46:44 +0500
committerunknown <svoj@mysql.com>2005-06-19 21:46:44 +0500
commit2c8ee686d8e626c4ccc54fd0534d5b4740d114ba (patch)
treefda3bfa7da994908f408724b76f0f38f71920c13 /configure.in
parentdb10586e809862f90e42932f61a421f2ca1dc46b (diff)
downloadmariadb-git-2c8ee686d8e626c4ccc54fd0534d5b4740d114ba.tar.gz
WL#2286 - Compile MySQL w/YASSL support
Fix for yaSSL link failures with Forte Developer 7, MIPSpro Compilers, Compaq C++. These compilers have problem with implicit template instantiation in archives (libyassl.a, libtaocrypt.a). Instantiate templates explicitly. Fix for yaSSL link failure on powermacg5 (gcc 3.3). When -O3 is specified gcc inlines __cxa_pure_virtual. This is wrong behavior, __cxa_pure_virtual must never be inlined. configure.in: Better CXX_VERSION guessing. EXPLICIT_TEMPLATE_INSTANTIATION macro indicates whether to instantiate templates explicitly. Instantiate templates explicitly on MIPSpro, Compaq, Forte. extra/yassl/src/crypto_wrapper.cpp: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. extra/yassl/src/template_instnt.cpp: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. More portable templates instantiation. extra/yassl/src/yassl_int.cpp: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. More portable templates instantiation. extra/yassl/taocrypt/include/runtime.hpp: Fix for link failure on powermacg5 (gcc 3.3). __cxa_pure_virtual must never be inlined. extra/yassl/taocrypt/src/algebra.cpp: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. extra/yassl/taocrypt/src/integer.cpp: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. extra/yassl/taocrypt/src/template_instnt.cpp: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/field.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/item.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/item_buff.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/mysqld.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/opt_range.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/set_var.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/slave.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/sql_acl.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/sql_class.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/sql_insert.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/sql_map.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/sql_select.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/sql_show.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION. sql/table.cc: Replace __GNUC__ by EXPLICIT_TEMPLATE_INSTANTIATION.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in14
1 files changed, 14 insertions, 0 deletions
diff --git a/configure.in b/configure.in
index d7a081ed6c5..90b9300cfd4 100644
--- a/configure.in
+++ b/configure.in
@@ -201,6 +201,8 @@ CXX_VERSION=`$CXX -version | grep -i version`
;;
*)
CXX_VERSION=`$CXX --version | sed 1q`
+CXX_VERSION=${CXX_VERSION:-`$CXX -V|sed 1q`} # trying harder for Sun and SGI
+CXX_VERSION=${CXX_VERSION:-`$CXX -V 2>&1|sed 1q`} # even harder for Alpha
;;
esac
if test $? -eq "0"
@@ -365,8 +367,20 @@ then
# Disable exceptions as they seams to create problems with gcc and threads.
# mysqld doesn't use run-time-type-checking, so we disable it.
CXXFLAGS="$CXXFLAGS -fno-implicit-templates -fno-exceptions -fno-rtti"
+ CXXFLAGS="$CXXFLAGS -DEXPLICIT_TEMPLATE_INSTANTIATION"
fi
+case $CXX_VERSION in
+ MIPSpro*)
+ CXXFLAGS="$CXXFLAGS -no_prelink -DEXPLICIT_TEMPLATE_INSTANTIATION"
+ ;;
+ Compaq*)
+ CXXFLAGS="$CXXFLAGS -nopt -DEXPLICIT_TEMPLATE_INSTANTIATION"
+ ;;
+ Forte*)
+ CXXFLAGS="$CXXFLAGS -instance=explicit -DEXPLICIT_TEMPLATE_INSTANTIATION"
+esac
+
# Avoid bug in fcntl on some versions of linux
AC_MSG_CHECKING("if we should use 'skip-locking' as default for $target_os")
# Any variation of Linux