From 4f71165544f62521d9fd15d9d7fb4ae2911600c1 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 14 Sep 2005 10:34:45 +0200 Subject: [PATCH 1/2] Cset exclude: msvensson@neptunus.(none)|ChangeSet|20050913150614|63378 extra/yassl/taocrypt/src/integer.cpp: Exclude --- extra/yassl/taocrypt/src/integer.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/extra/yassl/taocrypt/src/integer.cpp b/extra/yassl/taocrypt/src/integer.cpp index 01bd5b2ec94..71324b04b92 100644 --- a/extra/yassl/taocrypt/src/integer.cpp +++ b/extra/yassl/taocrypt/src/integer.cpp @@ -568,13 +568,13 @@ public: static word Add(word *C, const word *A, const word *B, unsigned int N); static word Subtract(word *C, const word *A, const word*B, unsigned int N); - static void Multiply2(word *C, const word *A, const word *B); - static word Multiply2Add(word *C, const word *A, const word *B); + static inline void Multiply2(word *C, const word *A, const word *B); + static inline word Multiply2Add(word *C, const word *A, const word *B); static void Multiply4(word *C, const word *A, const word *B); static void Multiply8(word *C, const word *A, const word *B); static inline unsigned int MultiplyRecursionLimit() {return 8;} - static void Multiply2Bottom(word *C, const word *A, const word *B); + static inline void Multiply2Bottom(word *C, const word *A, const word *B); static void Multiply4Bottom(word *C, const word *A, const word *B); static void Multiply8Bottom(word *C, const word *A, const word *B); static inline unsigned int MultiplyBottomRecursionLimit() {return 8;} @@ -668,7 +668,7 @@ void Portable::Multiply2(word *C, const word *A, const word *B) C[3] = t.GetHighHalf(); } -void Portable::Multiply2Bottom(word *C, const word *A, const word *B) +inline void Portable::Multiply2Bottom(word *C, const word *A, const word *B) { DWord t = DWord::Multiply(A[0], B[0]); C[0] = t.GetLowHalf(); From 21e1efc75582e3f999e869190c625f409fe1c125 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 15 Sep 2005 08:59:29 +0200 Subject: [PATCH 2/2] Bug #12526 yassl: Crashes in "integer.cpp" - Disable inlining in integer.cp for sparc solaris Cun C++ 5.6 config/ac-macros/yassl.m4: Detect sparc Solaris + Sun C++ 5.6 and disable inlining for integer.cpp extra/yassl/taocrypt/src/Makefile.am: Compile integer.cpp into a separate lib in order to use special CXXFLAGS Add the integer.cpp lib to libtaocrypt.la --- config/ac-macros/yassl.m4 | 11 +++++++++++ extra/yassl/taocrypt/src/Makefile.am | 7 +++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/config/ac-macros/yassl.m4 b/config/ac-macros/yassl.m4 index 92133339343..7af39db48be 100644 --- a/config/ac-macros/yassl.m4 +++ b/config/ac-macros/yassl.m4 @@ -20,6 +20,17 @@ AC_DEFUN([MYSQL_CHECK_YASSL], [ -L\$(top_builddir)/extra/yassl/taocrypt/src -ltaocrypt" openssl_includes="-I\$(top_srcdir)/extra/yassl/include" AC_DEFINE([HAVE_OPENSSL], [1], [Defined by configure. Using yaSSL for OpenSSL emulation.]) + + # System specific checks + yassl_integer_extra_cxxflags="" + case $SYSTEM_TYPE--$CXX_VERSION in + sparc*solaris*--*Sun*C++*5.6*) + # Disable inlining when compiling taocrypt/src/integer.cpp + yassl_integer_extra_cxxflags="+d" + ;; + esac + AC_SUBST([yassl_integer_extra_cxxflags]) + else yassl_dir="" AC_MSG_RESULT(no) diff --git a/extra/yassl/taocrypt/src/Makefile.am b/extra/yassl/taocrypt/src/Makefile.am index 4549c218d87..c4fc4607622 100644 --- a/extra/yassl/taocrypt/src/Makefile.am +++ b/extra/yassl/taocrypt/src/Makefile.am @@ -1,9 +1,12 @@ INCLUDES = -I../include -I../../mySTL -noinst_LTLIBRARIES = libtaocrypt.la +noinst_LTLIBRARIES = libtaocrypt.la libtaoint.la libtaocrypt_la_SOURCES = aes.cpp aestables.cpp algebra.cpp arc4.cpp asn.cpp \ - coding.cpp dh.cpp des.cpp dsa.cpp file.cpp hash.cpp integer.cpp \ + coding.cpp dh.cpp des.cpp dsa.cpp file.cpp hash.cpp \ md2.cpp md5.cpp misc.cpp random.cpp ripemd.cpp rsa.cpp sha.cpp \ template_instnt.cpp +libtaocrypt_la_LIBADD = libtaoint.la +libtaoint_la_SOURCES = integer.cpp +libtaoint_la_CXXFLAGS = @yassl_integer_extra_cxxflags@ EXTRA_DIST = ../include/*.hpp AM_CXXFLAGS = -DYASSL_PURE_C