Commit 5245f98c authored by msvensson@neptunus.(none)'s avatar msvensson@neptunus.(none)

Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0-ndb

into neptunus.(none):/home/msvensson/mysql/bug9626
parents acb83c67 b85c5ee2
...@@ -1110,3 +1110,8 @@ VC++Files/client/mysql_amd64.dsp ...@@ -1110,3 +1110,8 @@ VC++Files/client/mysql_amd64.dsp
client/mysqltestmanager-pwgen client/mysqltestmanager-pwgen
client/mysqltestmanagerc client/mysqltestmanagerc
tools/mysqltestmanager tools/mysqltestmanager
config.guess
config.sub
install-sh
ltmain.sh
missing
...@@ -7,17 +7,9 @@ commands="\ ...@@ -7,17 +7,9 @@ commands="\
$make -k distclean || true $make -k distclean || true
/bin/rm -rf */.deps/*.P config.cache innobase/config.cache bdb/build_unix/config.cache bdb/dist/autom4te.cache autom4te.cache innobase/autom4te.cache; /bin/rm -rf */.deps/*.P config.cache innobase/config.cache bdb/build_unix/config.cache bdb/dist/autom4te.cache autom4te.cache innobase/autom4te.cache;
aclocal || (echo \"Can't execute aclocal\" && exit 1)
autoheader || (echo \"Can't execute autoheader\" && exit 1) path=`dirname $0`
aclocal || (echo \"Can't execute aclocal\" && exit 1) . \"$path/autorun.sh\""
automake || (echo \"Can't execute automake\" && exit 1)
autoconf || (echo \"Can't execute autoconf\" && exit 1)
(cd bdb/dist && sh s_all)
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf)
if [ -d gemini ]
then
(cd gemini && aclocal && autoheader && aclocal && automake && autoconf)
fi"
if [ -z "$just_clean" ] if [ -z "$just_clean" ]
then then
......
#!/bin/sh
# Create MySQL autotools infrastructure
aclocal || (echo "Can't execute aclocal" && exit 1)
autoheader || (echo "Can't execute autoheader" && exit 1)
# --force means overwrite ltmain.sh script if it already exists
libtoolize --automake --force \
|| (echo "Can't execute libtoolize" && exit 1)
# --add-missing instructs automake to install missing auxiliary files
# and --force to overwrite them if they already exist
automake --add-missing --force \
|| (echo "Can't execute automake" && exit 1)
autoconf || (echo "Can't execute autoconf" && exit 1)
(cd bdb/dist && sh s_all)
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf)
...@@ -2,7 +2,9 @@ ...@@ -2,7 +2,9 @@
make -k clean make -k clean
/bin/rm -f */.deps/*.P */*.o /bin/rm -f */.deps/*.P */*.o
/bin/rm -f config.cache mysql-*.tar.gz /bin/rm -f config.cache mysql-*.tar.gz
aclocal; autoheader; aclocal; automake; autoconf
path=`dirname $0`
. "$path/autorun.sh"
CC=ccc CFLAGS="-fast -O3 -fomit-frame-pointer" CXX=gcc CXXFLAGS="-O6 -fomit-frame-pointer -felide-constructors -fno-exceptions -fno-rtti -mcpu=ev6 -Wa,-mev6" CXXLDFLAGS='/usr/lib/compaq/libots-2.2.7/libots.so /usr/lib/compaq/cpml-5.0.0/libcpml_ev6.a' ./configure --prefix=/usr/local/mysql --disable-shared --with-extra-charsets=complex --enable-thread-safe-client CC=ccc CFLAGS="-fast -O3 -fomit-frame-pointer" CXX=gcc CXXFLAGS="-O6 -fomit-frame-pointer -felide-constructors -fno-exceptions -fno-rtti -mcpu=ev6 -Wa,-mev6" CXXLDFLAGS='/usr/lib/compaq/libots-2.2.7/libots.so /usr/lib/compaq/cpml-5.0.0/libcpml_ev6.a' ./configure --prefix=/usr/local/mysql --disable-shared --with-extra-charsets=complex --enable-thread-safe-client
make make
......
...@@ -2,7 +2,9 @@ ...@@ -2,7 +2,9 @@
make -k clean make -k clean
/bin/rm -f */.deps/*.P */*.o /bin/rm -f */.deps/*.P */*.o
/bin/rm -f */.deps/*.P config.cache innobase/config.cache bdb/build_unix/config.cache mysql-*.tar.gz /bin/rm -f */.deps/*.P config.cache innobase/config.cache bdb/build_unix/config.cache mysql-*.tar.gz
aclocal; autoheader; aclocal; automake; autoconf
path=`dirname $0`
. "$path/autorun.sh"
CC=ccc CFLAGS="-fast" CXX=cxx CXXFLAGS="-fast -noexceptions -nortti" ./configure --prefix=/usr/local/mysql --disable-shared --with-extra-charsets=complex --enable-thread-safe-client --with-mysqld-ldflags=-non_shared --with-client-ldflags=-non_shared --without-extra-tools --disable-dependency-tracking CC=ccc CFLAGS="-fast" CXX=cxx CXXFLAGS="-fast -noexceptions -nortti" ./configure --prefix=/usr/local/mysql --disable-shared --with-extra-charsets=complex --enable-thread-safe-client --with-mysqld-ldflags=-non_shared --with-client-ldflags=-non_shared --without-extra-tools --disable-dependency-tracking
......
...@@ -2,7 +2,9 @@ ...@@ -2,7 +2,9 @@
make -k clean make -k clean
/bin/rm -f */.deps/*.P */*.o /bin/rm -f */.deps/*.P */*.o
/bin/rm -f */.deps/*.P config.cache innobase/config.cache bdb/build_unix/config.cache mysql-*.tar.gz /bin/rm -f */.deps/*.P config.cache innobase/config.cache bdb/build_unix/config.cache mysql-*.tar.gz
aclocal; autoheader; aclocal; automake; autoconf
path=`dirname $0`
. "$path/autorun.sh"
CFLAGS=-O1 CC=gcc CXX=gcc CXXFLAGS="-O1 -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql --with-debug --with-extra-charsets=complex --without-extra-tools CFLAGS=-O1 CC=gcc CXX=gcc CXXFLAGS="-O1 -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql --with-debug --with-extra-charsets=complex --without-extra-tools
make make
...@@ -62,14 +62,9 @@ done ...@@ -62,14 +62,9 @@ done
set -x set -x
make distclean make distclean
aclocal
autoheader
libtoolize --automake --force
automake --force --add-missing
autoconf
(cd bdb/dist && sh s_all) path=`dirname $0`
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf) . "$path/autorun.sh"
CC=cc CXX=aCC CFLAGS="$cflags" CXXFLAGS="$cxxflags" \ CC=cc CXX=aCC CFLAGS="$cflags" CXXFLAGS="$cxxflags" \
./configure --prefix=/usr/local/mysql --disable-shared \ ./configure --prefix=/usr/local/mysql --disable-shared \
......
gmake -k clean || true gmake -k clean || true
/bin/rm -f */.deps/*.P config.cache innobase/config.cache bdb/build_unix/config.cache /bin/rm -f */.deps/*.P config.cache innobase/config.cache bdb/build_unix/config.cache
aclocal && autoheader && aclocal && automake && autoconf path=`dirname $0`
(cd bdb/dist && sh s_all) . "$path/autorun.sh"
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf)
if [ -d gemini ]
then
(cd gemini && aclocal && autoheader && aclocal && automake && autoconf)
fi
CC=ecc CFLAGS="-w1 -DEXTRA_DEBUG -DSAFEMALLOC -DSAFE_MUTEX -O2" CXX=ecc CXXFLAGS="-w1 -DEXTRA_DEBUG -DSAFEMALLOC -DSAFE_MUTEX -O2" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-thread-safe-client --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --with-debug --with-innodb --with-embedded-server --with-archive-storage-engine CC=ecc CFLAGS="-w1 -DEXTRA_DEBUG -DSAFEMALLOC -DSAFE_MUTEX -O2" CXX=ecc CXXFLAGS="-w1 -DEXTRA_DEBUG -DSAFEMALLOC -DSAFE_MUTEX -O2" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-thread-safe-client --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --with-debug --with-innodb --with-embedded-server --with-archive-storage-engine
gmake gmake
...@@ -34,14 +34,9 @@ fi ...@@ -34,14 +34,9 @@ fi
set -x set -x
make distclean make distclean
aclocal
autoheader
libtoolize --automake --force
automake --force --add-missing
autoconf
(cd bdb/dist && sh s_all) path=`dirname $0`
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf) . "$path/autorun.sh"
# C options: # C options:
# -apo - auto-parallize for multiprocessors (implies -mp) # -apo - auto-parallize for multiprocessors (implies -mp)
......
#! /bin/sh
path=`dirname $0`
. "$path/SETUP.sh"
# Note that we can't use ccache with icc as the generated .deps file will
# then contain wrong information
CC=icc
CXX=icpc
CXXLD="$CXX -static-libcxa"
export CC CXX
extra_flags="$pentium_cflags $debug_cflags $max_cflags -USAFEMALLOC -UFORCE_INIT_OF_VARS -DHAVE_purify -DMYSQL_SERVER_SUFFIX=-valgrind-max"
# Disable following warnings as these are generated by header files:
# 161 unrecognized pragma
# 444 destructor for base class xxx is not virtual
# 279 controlling expression is constant
# 810 conversion from ulonglong to ulong with cast
# 981 operands are evaluated in unspecified order
# 1292 warning for unknown 'attribute' options
# 1469 "xxx" clobber ignored
# 1572 floating-point equality and inequality comparisons are unreliable
# In C++
# 869 parameter "xxx" was never referenced
# (Problem with virtual functions)
# 874 support for placement delete is disabled
c_warnings=""
cxx_warnings=""
extra_flags="-O3 -unroll2 -ip -mp -no-gcc -restrict"
base_cxxflags="-fno-exceptions -fno-rtti"
extra_configs="$pentium_configs $static_link"
. "$path/FINISH.sh"
#! /bin/sh
path=`dirname $0`
. "$path/SETUP.sh"
# Note that we can't use ccache with icc as the generated .deps file will
# then contain wrong information
CC=icc
CXX=icpc
export CC CXX
extra_flags="$pentium_cflags $debug_cflags $max_cflags -USAFEMALLOC -UFORCE_INIT_OF_VARS -DHAVE_purify -DMYSQL_SERVER_SUFFIX=-valgrind-max"
# Disable following warnings as these are generated by header files:
# 161 unrecognized pragma
# 444 destructor for base class xxx is not virtual
# 279 controlling expression is constant
# 810 conversion from ulonglong to ulong with cast
# 981 operands are evaluated in unspecified order
# 1292 warning for unknown 'attribute' options
# 1469 "xxx" clobber ignored
# 1572 floating-point equality and inequality comparisons are unreliable
# In C++
# 869 parameter "xxx" was never referenced
# (Problem with virtual functions)
# 874 support for placement delete is disabled
c_warnings="-Wall -Wcheck -wd161,444,279,810,981,1292,1469,1572"
cxx_warnings="$c_warnings -wd869,874"
base_cxxflags="-fno-exceptions -fno-rtti"
extra_configs="$pentium_configs $debug_configs"
. "$path/FINISH.sh"
...@@ -2,13 +2,9 @@ AM_MAKEFLAGS="-j 2" ...@@ -2,13 +2,9 @@ AM_MAKEFLAGS="-j 2"
gmake -k clean || true gmake -k clean || true
/bin/rm -f */.deps/*.P config.cache /bin/rm -f */.deps/*.P config.cache
aclocal && autoheader && aclocal && automake && autoconf
(cd bdb/dist && sh s_all) path=`dirname $0`
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf) . "$path/autorun.sh"
if [ -d gemini ]
then
(cd gemini && aclocal && autoheader && aclocal && automake && autoconf)
fi
export PATH=/usr/local/pgcc/bin:$PATH export PATH=/usr/local/pgcc/bin:$PATH
CFLAGS="-Wimplicit -Wreturn-type -Wid-clash-51 -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wimplicit-function-dec -Wimplicit-int -Wparentheses -Wsign-compare -Wwrite-strings -Wunused -O6 -mpentiumpro -fomit-frame-pointer -mstack-align-double" CXX=gcc CXXFLAGS="-Wimplicit -Wreturn-type -Wid-clash-51 -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wimplicit-function-dec -Wimplicit-int -Wparentheses -Wsign-compare -Wwrite-strings -Woverloaded-virtual -Wextern-inline -Wsign-promo -Wreorder -Wctor-dtor-privacy -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -O6 -fomit-frame-pointer -mpentiumpro -mstack-align-double" ./configure --prefix=/usr/local/mysql --enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static CFLAGS="-Wimplicit -Wreturn-type -Wid-clash-51 -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wimplicit-function-dec -Wimplicit-int -Wparentheses -Wsign-compare -Wwrite-strings -Wunused -O6 -mpentiumpro -fomit-frame-pointer -mstack-align-double" CXX=gcc CXXFLAGS="-Wimplicit -Wreturn-type -Wid-clash-51 -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wimplicit-function-dec -Wimplicit-int -Wparentheses -Wsign-compare -Wwrite-strings -Woverloaded-virtual -Wextern-inline -Wsign-promo -Wreorder -Wctor-dtor-privacy -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -O6 -fomit-frame-pointer -mpentiumpro -mstack-align-double" ./configure --prefix=/usr/local/mysql --enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static
......
#! /bin/sh
path=`dirname $0`
. "$path/SETUP.sh"
extra_flags="$pentium_cflags"
extra_configs="$pentium_configs --without-berkeley-db"
. "$path/FINISH.sh"
#! /bin/sh
path=`dirname $0`
. "$path/SETUP.sh"
extra_flags="$pentium_cflags $debug_cflags"
extra_configs="$pentium_configs $debug_configs --without-berkeley-db $static_link"
. "$path/FINISH.sh"
...@@ -3,14 +3,9 @@ ...@@ -3,14 +3,9 @@
gmake -k clean || true gmake -k clean || true
/bin/rm -f */.deps/*.P config.cache /bin/rm -f */.deps/*.P config.cache
aclocal && autoheader && aclocal && automake && autoconf path=`dirname $0`
(cd bdb/dist && sh s_all) . "$path/autorun.sh"
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf)
if [ -d gemini ]
then
(cd gemini && aclocal && autoheader && aclocal && automake && autoconf)
fi
CFLAGS="-g -Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Wunused -O3 -fno-omit-frame-pointer -mcpu=v8 -Wa,-xarch=v8plusa" CXX=gcc CXXFLAGS="-Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Woverloaded-virtual -Wsign-promo -Wreorder -Wctor-dtor-privacy -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -O3 -fno-omit-frame-pointer -mcpu=v8 -Wa,-xarch=v8plusa -g" ./configure --prefix=/usr/local/mysql --enable-assembler --with-extra-charsets=complex --enable-thread-safe-client CFLAGS="-g -Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Wunused -O3 -fno-omit-frame-pointer -mcpu=v8 -Wa,-xarch=v8plusa" CXX=gcc CXXFLAGS="-Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Woverloaded-virtual -Wsign-promo -Wreorder -Wctor-dtor-privacy -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -O3 -fno-omit-frame-pointer -mcpu=v8 -Wa,-xarch=v8plusa -g" ./configure --prefix=/usr/local/mysql --enable-assembler --with-extra-charsets=complex --enable-thread-safe-client
gmake -j 4 gmake -j 4
...@@ -3,13 +3,8 @@ ...@@ -3,13 +3,8 @@
gmake -k clean || true gmake -k clean || true
/bin/rm -f */.deps/*.P config.cache /bin/rm -f */.deps/*.P config.cache
aclocal && autoheader && aclocal && automake && autoconf path=`dirname $0`
(cd bdb/dist && sh s_all) . "$path/autorun.sh"
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf)
if [ -d gemini ]
then
(cd gemini && aclocal && autoheader && aclocal && automake && autoconf)
fi
CFLAGS="-g -Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Wunused -O3 -fno-omit-frame-pointer -mcpu=v8 -Wa,-xarch=v8plusa" CXX=gcc CXXFLAGS="-Wimplicit -Wreturn-type -Wid-clash-51 -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Woverloaded-virtual -Wsign-promo -Wreorder -Wctor-dtor-privacy -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -O3 -fno-omit-frame-pointer -mcpu=v8 -Wa,-xarch=v8plusa -g" ./configure --prefix=/usr/local/mysql --enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-debug CFLAGS="-g -Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Wunused -O3 -fno-omit-frame-pointer -mcpu=v8 -Wa,-xarch=v8plusa" CXX=gcc CXXFLAGS="-Wimplicit -Wreturn-type -Wid-clash-51 -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Woverloaded-virtual -Wsign-promo -Wreorder -Wctor-dtor-privacy -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -O3 -fno-omit-frame-pointer -mcpu=v8 -Wa,-xarch=v8plusa -g" ./configure --prefix=/usr/local/mysql --enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-debug
......
...@@ -3,13 +3,8 @@ ...@@ -3,13 +3,8 @@
gmake -k clean || true gmake -k clean || true
/bin/rm -f */.deps/*.P config.cache /bin/rm -f */.deps/*.P config.cache
aclocal && autoheader && aclocal && automake && autoconf path=`dirname $0`
(cd bdb/dist && sh s_all) . "$path/autorun.sh"
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf)
if [ -d gemini ]
then
(cd gemini && aclocal && autoheader && aclocal && automake && autoconf)
fi
# Assume Forte is installed in /opt/SUNWSpro # Assume Forte is installed in /opt/SUNWSpro
......
...@@ -33,9 +33,9 @@ done ...@@ -33,9 +33,9 @@ done
gmake -k clean || true gmake -k clean || true
/bin/rm -f */.deps/*.P config.cache /bin/rm -f */.deps/*.P config.cache
aclocal && autoheader && aclocal && automake && autoconf
(cd bdb/dist && sh s_all) path=`dirname $0`
(cd innobase && aclocal && autoheader && aclocal && automake && autoconf) . "$path/autorun.sh"
CFLAGS="-g -Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wimplicit-int -Wparentheses -Wsign-compare -Wwrite-strings -Wunused -DHAVE_purify -DEXTRA_DEBUG -O2" CXX=gcc CXXLD=g++ CXXFLAGS="-g -Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Woverloaded-virtual -Wsign-promo -Wreorder -Wctor-dtor-privacy -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -DHAVE_purify -DEXTRA_DEBUG -O2" ./configure --prefix=/usr/local/mysql --enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-berkeley-db --with-embedded-server --with-innodb $EXTRA_CONFIG_FLAGS CFLAGS="-g -Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wimplicit-int -Wparentheses -Wsign-compare -Wwrite-strings -Wunused -DHAVE_purify -DEXTRA_DEBUG -O2" CXX=gcc CXXLD=g++ CXXFLAGS="-g -Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare -Wwrite-strings -Woverloaded-virtual -Wsign-promo -Wreorder -Wctor-dtor-privacy -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -DHAVE_purify -DEXTRA_DEBUG -O2" ./configure --prefix=/usr/local/mysql --enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-berkeley-db --with-embedded-server --with-innodb $EXTRA_CONFIG_FLAGS
......
...@@ -57,6 +57,7 @@ evgen@moonbone.local ...@@ -57,6 +57,7 @@ evgen@moonbone.local
gbichot@production.mysql.com gbichot@production.mysql.com
gbichot@quadita2.mysql.com gbichot@quadita2.mysql.com
gbichot@quadxeon.mysql.com gbichot@quadxeon.mysql.com
geert@kriem.kemuri.org
georg@beethoven.local georg@beethoven.local
georg@beethoven.site georg@beethoven.site
georg@lmy002.wdf.sap.corp georg@lmy002.wdf.sap.corp
...@@ -242,6 +243,8 @@ salle@geopard.online.bg ...@@ -242,6 +243,8 @@ salle@geopard.online.bg
salle@vafla.home salle@vafla.home
salle@vafla.online.bg salle@vafla.online.bg
sasha@mysql.sashanet.com sasha@mysql.sashanet.com
schwenke@lmy003.wdf.sap.corp
schwenke@lmy003.xl.local
serg@build.mysql.com serg@build.mysql.com
serg@build.mysql2.com serg@build.mysql2.com
serg@mysql.com serg@mysql.com
...@@ -279,6 +282,7 @@ tonu@x3.internalnet ...@@ -279,6 +282,7 @@ tonu@x3.internalnet
tsmith@build.mysql.com tsmith@build.mysql.com
tulin@build.mysql.com tulin@build.mysql.com
tulin@dl145b.mysql.com tulin@dl145b.mysql.com
tulin@dl145c.mysql.com
tulin@mysql.com tulin@mysql.com
ulli@morbus.(none) ulli@morbus.(none)
venu@hundin.mysql.fi venu@hundin.mysql.fi
......
...@@ -330,6 +330,10 @@ SOURCE=..\mysys\my_alloc.c ...@@ -330,6 +330,10 @@ SOURCE=..\mysys\my_alloc.c
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=..\mysys\my_chsize.c
# End Source File
# Begin Source File
SOURCE=..\mysys\my_compress.c SOURCE=..\mysys\my_compress.c
# ADD CPP /I "../zlib" # ADD CPP /I "../zlib"
# End Source File # End Source File
......
...@@ -219,6 +219,10 @@ SOURCE=..\mysys\default.c ...@@ -219,6 +219,10 @@ SOURCE=..\mysys\default.c
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=..\mysys\default_modify.c
# End Source File
# Begin Source File
SOURCE=.\dll.c SOURCE=.\dll.c
# End Source File # End Source File
# Begin Source File # Begin Source File
...@@ -303,6 +307,10 @@ SOURCE=..\mysys\my_alloc.c ...@@ -303,6 +307,10 @@ SOURCE=..\mysys\my_alloc.c
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=..\mysys\my_chsize.c
# End Source File
# Begin Source File
SOURCE=..\mysys\my_compress.c SOURCE=..\mysys\my_compress.c
# End Source File # End Source File
# Begin Source File # Begin Source File
...@@ -387,6 +395,10 @@ SOURCE=..\mysys\my_rename.c ...@@ -387,6 +395,10 @@ SOURCE=..\mysys\my_rename.c
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=..\mysys\my_seek.c
# End Source File
# Begin Source File
SOURCE=..\mysys\my_static.c SOURCE=..\mysys\my_static.c
# End Source File # End Source File
# Begin Source File # Begin Source File
......
...@@ -180,6 +180,10 @@ SOURCE=..\mysys\default.c ...@@ -180,6 +180,10 @@ SOURCE=..\mysys\default.c
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=..\mysys\default_modify.c
# End Source File
# Begin Source File
SOURCE=..\sql\derror.cpp SOURCE=..\sql\derror.cpp
# End Source File # End Source File
# Begin Source File # Begin Source File
......
...@@ -204,6 +204,10 @@ SOURCE=.\default.c ...@@ -204,6 +204,10 @@ SOURCE=.\default.c
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=.\default_modify.c
# End Source File
# Begin Source File
SOURCE=.\errors.c SOURCE=.\errors.c
# End Source File # End Source File
# Begin Source File # Begin Source File
......
...@@ -49,5 +49,5 @@ enum options_client ...@@ -49,5 +49,5 @@ enum options_client
#ifdef HAVE_NDBCLUSTER_DB #ifdef HAVE_NDBCLUSTER_DB
OPT_NDBCLUSTER, OPT_NDB_CONNECTSTRING, OPT_NDBCLUSTER, OPT_NDB_CONNECTSTRING,
#endif #endif
OPT_IGNORE_TABLE,OPT_INSERT_IGNORE OPT_IGNORE_TABLE,OPT_INSERT_IGNORE,OPT_SHOW_WARNINGS
}; };
...@@ -135,7 +135,8 @@ static my_bool info_flag=0,ignore_errors=0,wait_flag=0,quick=0, ...@@ -135,7 +135,8 @@ static my_bool info_flag=0,ignore_errors=0,wait_flag=0,quick=0,
opt_xml=0,opt_nopager=1, opt_outfile=0, named_cmds= 0, opt_xml=0,opt_nopager=1, opt_outfile=0, named_cmds= 0,
tty_password= 0, opt_nobeep=0, opt_reconnect=1, tty_password= 0, opt_nobeep=0, opt_reconnect=1,
default_charset_used= 0, opt_secure_auth= 0, default_charset_used= 0, opt_secure_auth= 0,
default_pager_set= 0, opt_sigint_ignore= 0; default_pager_set= 0, opt_sigint_ignore= 0,
show_warnings = 0;
static ulong opt_max_allowed_packet, opt_net_buffer_length; static ulong opt_max_allowed_packet, opt_net_buffer_length;
static uint verbose=0,opt_silent=0,opt_mysql_port=0, opt_local_infile=0; static uint verbose=0,opt_silent=0,opt_mysql_port=0, opt_local_infile=0;
static my_string opt_mysql_unix_port=0; static my_string opt_mysql_unix_port=0;
...@@ -194,7 +195,8 @@ static int com_quit(String *str,char*), ...@@ -194,7 +195,8 @@ static int com_quit(String *str,char*),
com_use(String *str,char*), com_source(String *str, char*), com_use(String *str,char*), com_source(String *str, char*),
com_rehash(String *str, char*), com_tee(String *str, char*), com_rehash(String *str, char*), com_tee(String *str, char*),
com_notee(String *str, char*), com_notee(String *str, char*),
com_prompt(String *str, char*), com_delimiter(String *str, char*); com_prompt(String *str, char*), com_delimiter(String *str, char*),
com_warnings(String *str, char*), com_nowarnings(String *str, char*);
#ifdef USE_POPEN #ifdef USE_POPEN
static int com_nopager(String *str, char*), com_pager(String *str, char*), static int com_nopager(String *str, char*), com_pager(String *str, char*),
...@@ -266,6 +268,10 @@ static COMMANDS commands[] = { ...@@ -266,6 +268,10 @@ static COMMANDS commands[] = {
"Set outfile [to_outfile]. Append everything into given outfile." }, "Set outfile [to_outfile]. Append everything into given outfile." },
{ "use", 'u', com_use, 1, { "use", 'u', com_use, 1,
"Use another database. Takes database name as argument." }, "Use another database. Takes database name as argument." },
{ "warnings", 'W', com_warnings, 0,
"Show warnings after every statement." },
{ "nowarning", 'w', com_nowarnings, 0,
"Don't show warnings after every statement." },
/* Get bash-like expansion for some commands */ /* Get bash-like expansion for some commands */
{ "create table", 0, 0, 0, ""}, { "create table", 0, 0, 0, ""},
{ "create database", 0, 0, 0, ""}, { "create database", 0, 0, 0, ""},
...@@ -323,6 +329,7 @@ static void print_table_data_html(MYSQL_RES *result); ...@@ -323,6 +329,7 @@ static void print_table_data_html(MYSQL_RES *result);
static void print_table_data_xml(MYSQL_RES *result); static void print_table_data_xml(MYSQL_RES *result);
static void print_tab_data(MYSQL_RES *result); static void print_tab_data(MYSQL_RES *result);
static void print_table_data_vertically(MYSQL_RES *result); static void print_table_data_vertically(MYSQL_RES *result);
static void print_warnings(void);
static ulong start_timer(void); static ulong start_timer(void);
static void end_timer(ulong start_time,char *buff); static void end_timer(ulong start_time,char *buff);
static void mysql_end_timer(ulong start_time,char *buff); static void mysql_end_timer(ulong start_time,char *buff);
...@@ -693,6 +700,9 @@ static struct my_option my_long_options[] = ...@@ -693,6 +700,9 @@ static struct my_option my_long_options[] =
{"secure-auth", OPT_SECURE_AUTH, "Refuse client connecting to server if it" {"secure-auth", OPT_SECURE_AUTH, "Refuse client connecting to server if it"
" uses old (pre-4.1.1) protocol", (gptr*) &opt_secure_auth, " uses old (pre-4.1.1) protocol", (gptr*) &opt_secure_auth,
(gptr*) &opt_secure_auth, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0}, (gptr*) &opt_secure_auth, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0},
{"show-warnings", OPT_SHOW_WARNINGS, "Show warnings after every statement.",
(gptr*) &show_warnings, (gptr*) &show_warnings, 0, GET_BOOL, NO_ARG,
0, 0, 0, 0, 0, 0},
{ 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}
}; };
...@@ -1962,6 +1972,13 @@ com_go(String *buffer,char *line __attribute__((unused))) ...@@ -1962,6 +1972,13 @@ com_go(String *buffer,char *line __attribute__((unused)))
if (err >= 1) if (err >= 1)
error= put_error(&mysql); error= put_error(&mysql);
if (show_warnings == 1 && warnings >= 1) /* Show warnings if any */
{
init_pager();
print_warnings();
end_pager();
}
if (!error && !status.batch && if (!error && !status.batch &&
(mysql.server_status & SERVER_STATUS_DB_DROPPED)) (mysql.server_status & SERVER_STATUS_DB_DROPPED))
get_current_db(); get_current_db();
...@@ -2077,7 +2094,8 @@ print_table_data(MYSQL_RES *result) ...@@ -2077,7 +2094,8 @@ print_table_data(MYSQL_RES *result)
separator.fill(separator.length()+length+2,'-'); separator.fill(separator.length()+length+2,'-');
separator.append('+'); separator.append('+');
} }
tee_puts(separator.c_ptr_safe(), PAGER); separator.append('\0'); // End marker for \0
tee_puts((char*) separator.ptr(), PAGER);
if (column_names) if (column_names)
{ {
mysql_field_seek(result,0); mysql_field_seek(result,0);
...@@ -2090,7 +2108,7 @@ print_table_data(MYSQL_RES *result) ...@@ -2090,7 +2108,7 @@ print_table_data(MYSQL_RES *result)
num_flag[off]= IS_NUM(field->type); num_flag[off]= IS_NUM(field->type);
} }
(void) tee_fputs("\n", PAGER); (void) tee_fputs("\n", PAGER);
tee_puts(separator.c_ptr(), PAGER); tee_puts((char*) separator.ptr(), PAGER);
} }
while ((cur= mysql_fetch_row(result))) while ((cur= mysql_fetch_row(result)))
...@@ -2119,7 +2137,7 @@ print_table_data(MYSQL_RES *result) ...@@ -2119,7 +2137,7 @@ print_table_data(MYSQL_RES *result)
} }
(void) tee_fputs("\n", PAGER); (void) tee_fputs("\n", PAGER);
} }
tee_puts(separator.c_ptr(), PAGER); tee_puts((char*) separator.ptr(), PAGER);
my_afree((gptr) num_flag); my_afree((gptr) num_flag);
} }
...@@ -2219,6 +2237,34 @@ print_table_data_vertically(MYSQL_RES *result) ...@@ -2219,6 +2237,34 @@ print_table_data_vertically(MYSQL_RES *result)
} }
} }
/* print_warnings should be called right after executing a statement */
static void
print_warnings()
{
char query[30];
MYSQL_RES *result;
MYSQL_ROW cur;
/* Get the warnings */
strmov(query,"show warnings");
mysql_real_query_for_lazy(query,strlen(query));
mysql_store_result_for_lazy(&result);
/* Bail out when no warnings */
my_ulonglong num_rows = mysql_num_rows(result);
if (num_rows == 0)
{
mysql_free_result(result);
return;
}
/* Print the warnings */
while ((cur= mysql_fetch_row(result)))
{
tee_fprintf(PAGER, "%s (Code %s): %s\n", cur[0], cur[1], cur[2]);
}
mysql_free_result(result);
}
static const char static const char
*array_value(const char **array, char key) *array_value(const char **array, char key)
...@@ -2715,6 +2761,23 @@ com_use(String *buffer __attribute__((unused)), char *line) ...@@ -2715,6 +2761,23 @@ com_use(String *buffer __attribute__((unused)), char *line)
return 0; return 0;
} }
static int
com_warnings(String *buffer __attribute__((unused)),
char *line __attribute__((unused)))
{
show_warnings = 1;
put_info("Show warnings enabled.",INFO_INFO);
return 0;
}
static int
com_nowarnings(String *buffer __attribute__((unused)),
char *line __attribute__((unused)))
{
show_warnings = 0;
put_info("Show warnings disabled.",INFO_INFO);
return 0;
}
/* /*
Gets argument from a command on the command line. If get_next_arg is Gets argument from a command on the command line. If get_next_arg is
......
This diff is collapsed.
...@@ -2024,11 +2024,11 @@ my_bool end_of_query(int c) ...@@ -2024,11 +2024,11 @@ my_bool end_of_query(int c)
int read_line(char* buf, int size) int read_line(char* buf, int size)
{ {
int c; int c;
char quote;
char* p= buf, *buf_end= buf + size - 1; char* p= buf, *buf_end= buf + size - 1;
int no_save= 0; int no_save= 0;
enum {R_NORMAL, R_Q1, R_ESC_Q_Q1, R_ESC_Q_Q2, enum {R_NORMAL, R_Q, R_Q_IN_Q, R_SLASH_IN_Q,
R_ESC_SLASH_Q1, R_ESC_SLASH_Q2, R_COMMENT, R_LINE_START} state= R_LINE_START;
R_Q2, R_COMMENT, R_LINE_START} state= R_LINE_START;
DBUG_ENTER("read_line"); DBUG_ENTER("read_line");
start_lineno= *lineno; start_lineno= *lineno;
...@@ -2063,10 +2063,11 @@ int read_line(char* buf, int size) ...@@ -2063,10 +2063,11 @@ int read_line(char* buf, int size)
*p= 0; *p= 0;
DBUG_RETURN(0); DBUG_RETURN(0);
} }
else if (c == '\'') else if (c == '\'' || c == '"' || c == '`')
state = R_Q1; {
else if (c == '"') quote= c;
state = R_Q2; state= R_Q;
}
else if (c == '\n') else if (c == '\n')
{ {
state = R_LINE_START; state = R_LINE_START;
...@@ -2101,55 +2102,36 @@ int read_line(char* buf, int size) ...@@ -2101,55 +2102,36 @@ int read_line(char* buf, int size)
*p= 0; *p= 0;
DBUG_RETURN(0); DBUG_RETURN(0);
} }
else if (c == '\'') else if (c == '\'' || c == '"' || c == '`')
state= R_Q1;
else if (c == '"')
state= R_Q2;
else
state= R_NORMAL;
break;
case R_Q1:
if (c == '\'')
state= R_ESC_Q_Q1;
else if (c == '\\')
state= R_ESC_SLASH_Q1;
break;
case R_ESC_Q_Q1:
if (end_of_query(c))
{ {
*p= 0; quote= c;
DBUG_RETURN(0); state= R_Q;
} }
if (c != '\'')
state= R_NORMAL;
else else
state= R_Q1; state= R_NORMAL;
break;
case R_ESC_SLASH_Q1:
state= R_Q1;
break; break;
case R_Q2: case R_Q:
if (c == '"') if (c == quote)
state= R_ESC_Q_Q2; state= R_Q_IN_Q;
else if (c == '\\') else if (c == '\\')
state= R_ESC_SLASH_Q2; state= R_SLASH_IN_Q;
break; break;
case R_ESC_Q_Q2: case R_Q_IN_Q:
if (end_of_query(c)) if (end_of_query(c))
{ {
*p= 0; *p= 0;
DBUG_RETURN(0); DBUG_RETURN(0);
} }
if (c != '"') if (c != quote)
state= R_NORMAL; state= R_NORMAL;
else else
state= R_Q2; state= R_Q;
break; break;
case R_ESC_SLASH_Q2: case R_SLASH_IN_Q:
state= R_Q2; state= R_Q;
break; break;
} }
if (!no_save) if (!no_save)
......
...@@ -87,7 +87,7 @@ case $FLAG in ...@@ -87,7 +87,7 @@ case $FLAG in
cat $FILES | $AWK ' cat $FILES | $AWK '
BEGIN { BEGIN {
printf("/* Automatically generated file, do not edit */\n"); printf("/* Automatically generated file, do not edit */\n");
printf("#include \"sys.h\"\n#include \"el.h\"\n"); printf("#include \"config.h\"\n#include \"el.h\"\n");
printf("private const struct el_bindings_t el_func_help[] = {\n"); printf("private const struct el_bindings_t el_func_help[] = {\n");
low = "abcdefghijklmnopqrstuvwxyz_"; low = "abcdefghijklmnopqrstuvwxyz_";
high = "ABCDEFGHIJKLMNOPQRSTUVWXYZ_"; high = "ABCDEFGHIJKLMNOPQRSTUVWXYZ_";
...@@ -170,7 +170,7 @@ case $FLAG in ...@@ -170,7 +170,7 @@ case $FLAG in
cat $FILES | $AWK '/el_action_t/ { print $3 }' | sort | $AWK ' cat $FILES | $AWK '/el_action_t/ { print $3 }' | sort | $AWK '
BEGIN { BEGIN {
printf("/* Automatically generated file, do not edit */\n"); printf("/* Automatically generated file, do not edit */\n");
printf("#include \"sys.h\"\n#include \"el.h\"\n"); printf("#include \"config.h\"\n#include \"el.h\"\n");
printf("private const el_func_t el_func[] = {"); printf("private const el_func_t el_func[] = {");
maxlen = 80; maxlen = 80;
needn = 1; needn = 1;
......
...@@ -70,10 +70,10 @@ extern char *alloca (); ...@@ -70,10 +70,10 @@ extern char *alloca ();
#include <fcntl.h> #include <fcntl.h>
#include <vis.h> #include <vis.h>
#include "readline/readline.h"
#include "el.h" #include "el.h"
#include "fcns.h" /* for EL_NUM_FCNS */ #include "fcns.h" /* for EL_NUM_FCNS */
#include "histedit.h" #include "histedit.h"
#include "readline/readline.h"
/* for rl_complete() */ /* for rl_complete() */
#define TAB '\r' #define TAB '\r'
......
...@@ -73,7 +73,7 @@ typedef KEYMAP_ENTRY *Keymap; ...@@ -73,7 +73,7 @@ typedef KEYMAP_ENTRY *Keymap;
#ifndef CTRL #ifndef CTRL
#include <sys/ioctl.h> #include <sys/ioctl.h>
#ifdef __GLIBC__ #if defined(__GLIBC__) || defined(__MWERKS__)
#include <sys/ttydefaults.h> #include <sys/ttydefaults.h>
#endif #endif
#ifndef CTRL #ifndef CTRL
......
...@@ -37,6 +37,7 @@ ...@@ -37,6 +37,7 @@
/* /*
* search.c: History and character search functions * search.c: History and character search functions
*/ */
#include <sys/types.h>
#include <stdlib.h> #include <stdlib.h>
#if defined(REGEX) #if defined(REGEX)
#include <regex.h> #include <regex.h>
......
This diff is collapsed.
This diff is collapsed.
...@@ -38,7 +38,7 @@ AC_LANG_PUSH(C++) ...@@ -38,7 +38,7 @@ AC_LANG_PUSH(C++)
if test "$ac_cv_prog_gxx" = "yes" if test "$ac_cv_prog_gxx" = "yes"
then then
# Add -Werror, remove -fbranch-probabilities (Bug #268) # Add -Werror, remove -fbranch-probabilities (Bug #268)
CXXFLAGS=`echo $CXXFLAGS -Werror | sed 's/-fbranch-probabilities//'` CXXFLAGS=`echo "$CXXFLAGS -Werror" | sed -e 's/-fbranch-probabilities//; s/-Wall//; s/-Wcheck//'`
fi fi
mysql_cv_btype_last_arg_accept=none mysql_cv_btype_last_arg_accept=none
[AC_TRY_COMPILE([#if defined(inline) [AC_TRY_COMPILE([#if defined(inline)
...@@ -98,7 +98,7 @@ AC_LANG_PUSH(C++) ...@@ -98,7 +98,7 @@ AC_LANG_PUSH(C++)
if test "$ac_cv_prog_gxx" = "yes" if test "$ac_cv_prog_gxx" = "yes"
then then
# Add -Werror, remove -fbranch-probabilities (Bug #268) # Add -Werror, remove -fbranch-probabilities (Bug #268)
CXXFLAGS=`echo $CXXFLAGS -Werror | sed 's/-fbranch-probabilities//'` CXXFLAGS=`echo "$CXXFLAGS -Werror" | sed -e 's/-fbranch-probabilities//; s/-Wall//; s/-Wcheck//'`
fi fi
mysql_cv_btype_struct_rlimit=none mysql_cv_btype_struct_rlimit=none
[AC_TRY_COMPILE([#if defined(inline) [AC_TRY_COMPILE([#if defined(inline)
......
...@@ -359,6 +359,14 @@ AC_SUBST(INSTALL_SCRIPT) ...@@ -359,6 +359,14 @@ AC_SUBST(INSTALL_SCRIPT)
export CC CXX CFLAGS LD LDFLAGS AR export CC CXX CFLAGS LD LDFLAGS AR
if test "$GCC" = "yes"
then
# mysqld requires -fno-implicit-templates.
# 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"
fi
# Avoid bug in fcntl on some versions of linux # Avoid bug in fcntl on some versions of linux
AC_MSG_CHECKING("if we should use 'skip-locking' as default for $target_os") AC_MSG_CHECKING("if we should use 'skip-locking' as default for $target_os")
# Any variation of Linux # Any variation of Linux
...@@ -1374,20 +1382,20 @@ then ...@@ -1374,20 +1382,20 @@ then
AC_MSG_CHECKING("for gcc") AC_MSG_CHECKING("for gcc")
if expr "$CC" : ".*gcc.*" if expr "$CC" : ".*gcc.*"
then then
CC="$CC -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CC="$CC -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
CXX="$CXX -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CXX="$CXX -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
else else
CC="$CC -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CC="$CC -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
CXX="$CXX -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CXX="$CXX -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
fi fi
else else
{ AC_MSG_ERROR([configure: error: Can't find thread libs on SCO UnixWare7. See the Installation chapter in the Reference Manual.]) }; AC_MSG_ERROR([configure: error: Can't find thread libs on SCO UnixWare7. See the Installation chapter in the Reference Manual.])
fi fi
else else
AC_MSG_RESULT("no") AC_MSG_RESULT("no")
fi fi
else else
AC_MSG_ERROR([On SCO UNIX MySQL requires that the FSUThreads package is installed. See the Installation chapter in the Reference Manual.]); AC_MSG_ERROR([On SCO UNIX MySQL requires that the FSUThreads package is installed. See the Installation chapter in the Reference Manual.])
fi fi
else else
AC_MSG_RESULT("no") AC_MSG_RESULT("no")
...@@ -1419,15 +1427,15 @@ then ...@@ -1419,15 +1427,15 @@ then
AC_MSG_CHECKING("for gcc") AC_MSG_CHECKING("for gcc")
if expr "$CC" : ".*gcc.*" if expr "$CC" : ".*gcc.*"
then then
CC="$CC -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CC="$CC -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
CXX="$CXX -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CXX="$CXX -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
else else
CC="$CC -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CC="$CC -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
CXX="$CXX -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CXX="$CXX -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
fi fi
AC_MSG_RESULT("yes") AC_MSG_RESULT("yes")
else else
{ AC_MSG_ERROR([configure: error: Can't find thread libs on SCO UnixWare7. See the Installation chapter in the Reference Manual.]) }; AC_MSG_ERROR([configure: error: Can't find thread libs on SCO UnixWare7. See the Installation chapter in the Reference Manual.])
fi fi
else else
AC_MSG_RESULT("no") AC_MSG_RESULT("no")
...@@ -1462,15 +1470,15 @@ then ...@@ -1462,15 +1470,15 @@ then
AC_MSG_CHECKING("for gcc") AC_MSG_CHECKING("for gcc")
if expr "$CC" : ".*gcc.*" if expr "$CC" : ".*gcc.*"
then then
CC="$CC -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CC="$CC -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
CXX="$CXX -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CXX="$CXX -pthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
else else
CC="$CC -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CC="$CC -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
CXX="$CXX -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"; CXX="$CXX -Kthread -DUNIXWARE_7 -DHAVE_BROKEN_RWLOCK"
fi fi
AC_MSG_RESULT("yes") AC_MSG_RESULT("yes")
else else
{ AC_MSG_ERROR([configure: error: Can't find thread libs on Caldera OpenUNIX 8. See the Installation chapter in the Reference Manual.]) }; AC_MSG_ERROR([configure: error: Can't find thread libs on Caldera OpenUNIX 8. See the Installation chapter in the Reference Manual.])
fi fi
else else
AC_MSG_RESULT("no") AC_MSG_RESULT("no")
...@@ -1804,6 +1812,7 @@ fi ...@@ -1804,6 +1812,7 @@ fi
fi fi
AC_CHECK_TYPES([sigset_t, off_t], [], [], [#include <sys/types.h>]) AC_CHECK_TYPES([sigset_t, off_t], [], [], [#include <sys/types.h>])
AC_CHECK_TYPES([size_t], [], [], [#include <stdio.h>]) AC_CHECK_TYPES([size_t], [], [], [#include <stdio.h>])
AC_CHECK_TYPES([u_int32_t])
MYSQL_PTHREAD_YIELD MYSQL_PTHREAD_YIELD
...@@ -1957,9 +1966,12 @@ AC_LANG_CPLUSPLUS ...@@ -1957,9 +1966,12 @@ AC_LANG_CPLUSPLUS
# with respect to ANSI C++ # with respect to ANSI C++
# We also remove the -fbranch-probabilities option as this will give warnings # We also remove the -fbranch-probabilities option as this will give warnings
# about not profiled code, which confuses configure # about not profiled code, which confuses configure
# We also must remove -W and -Wcheck which on icc produces warnings that
# we don't want to catch with -Werror
if test "$ac_cv_prog_gxx" = "yes" -a "$with_other_libc" = "no" if test "$ac_cv_prog_gxx" = "yes" -a "$with_other_libc" = "no"
then then
CXXFLAGS=`echo "$CXXFLAGS -Werror" | sed 's/-fbranch-probabilities//'` CXXFLAGS=`echo "$CXXFLAGS -Werror" | sed -e 's/-fbranch-probabilities//; s/-Wall//; s/-Wcheck//'`
fi fi
AC_TRY_COMPILE( AC_TRY_COMPILE(
...@@ -1994,7 +2006,7 @@ AC_LANG_SAVE ...@@ -1994,7 +2006,7 @@ AC_LANG_SAVE
AC_LANG_CPLUSPLUS AC_LANG_CPLUSPLUS
if test "$ac_cv_prog_gxx" = "yes" -a "$with_other_libc" = "no" if test "$ac_cv_prog_gxx" = "yes" -a "$with_other_libc" = "no"
then then
CXXFLAGS=`echo "$CXXFLAGS -Werror" | sed 's/-fbranch-probabilities//'` CXXFLAGS=`echo "$CXXFLAGS -Werror" | sed -e 's/-fbranch-probabilities//; s/-Wall//; s/-Wcheck//'`
fi fi
AC_TRY_COMPILE( AC_TRY_COMPILE(
[#undef inline [#undef inline
...@@ -2027,7 +2039,7 @@ AC_LANG_SAVE ...@@ -2027,7 +2039,7 @@ AC_LANG_SAVE
AC_LANG_CPLUSPLUS AC_LANG_CPLUSPLUS
if test "$ac_cv_prog_gxx" = "yes" -a "$with_other_libc" = "no" if test "$ac_cv_prog_gxx" = "yes" -a "$with_other_libc" = "no"
then then
CXXFLAGS=`echo "$CXXFLAGS -Werror" | sed 's/-fbranch-probabilities//'` CXXFLAGS=`echo "$CXXFLAGS -Werror" | sed -e 's/-fbranch-probabilities//; s/-Wall//; s/-Wcheck//'`
fi fi
AC_TRY_COMPILE( AC_TRY_COMPILE(
[#undef inline [#undef inline
......
This diff is collapsed.
...@@ -63,7 +63,7 @@ typedef struct st_pointer_array { /* when using array-strings */ ...@@ -63,7 +63,7 @@ typedef struct st_pointer_array { /* when using array-strings */
#define LAST_CHAR_CODE 259 #define LAST_CHAR_CODE 259
typedef struct st_replace { typedef struct st_replace {
bool found; my_bool found;
struct st_replace *next[256]; struct st_replace *next[256];
} REPLACE; } REPLACE;
...@@ -80,19 +80,18 @@ typedef struct st_replace_found { ...@@ -80,19 +80,18 @@ typedef struct st_replace_found {
/* functions defined in this file */ /* functions defined in this file */
extern int main(int argc,char * *argv);
static int static_get_options(int *argc,char * * *argv); static int static_get_options(int *argc,char * * *argv);
static int get_replace_strings(int *argc,char * * *argv, static int get_replace_strings(int *argc,char * * *argv,
POINTER_ARRAY *from_array, POINTER_ARRAY *from_array,
POINTER_ARRAY *to_array); POINTER_ARRAY *to_array);
int insert_pointer_name(POINTER_ARRAY *pa, my_string name); static int insert_pointer_name(POINTER_ARRAY *pa, my_string name);
void free_pointer_array(POINTER_ARRAY *pa); static void free_pointer_array(POINTER_ARRAY *pa);
static int convert_pipe(REPLACE *,FILE *,FILE *); static int convert_pipe(REPLACE *,FILE *,FILE *);
static int convert_file(REPLACE *, my_string); static int convert_file(REPLACE *, my_string);
REPLACE *init_replace(my_string *from, my_string *to,uint count, my_string static REPLACE *init_replace(my_string *from, my_string *to,uint count,
word_end_chars); my_string word_end_chars);
uint replace_strings(REPLACE *rep, my_string *start,uint *max_length, static uint replace_strings(REPLACE *rep, my_string *start,uint *max_length,
my_string from); my_string from);
static int initialize_buffer(void); static int initialize_buffer(void);
static void reset_buffer(void); static void reset_buffer(void);
static void free_buffer(void); static void free_buffer(void);
...@@ -101,9 +100,7 @@ static int silent=0,verbose=0,updated=0; ...@@ -101,9 +100,7 @@ static int silent=0,verbose=0,updated=0;
/* The main program */ /* The main program */
int main(argc,argv) int main(int argc, char *argv[])
int argc;
char *argv[];
{ {
int i,error; int i,error;
char word_end_chars[256],*pos; char word_end_chars[256],*pos;
...@@ -118,7 +115,7 @@ char *argv[]; ...@@ -118,7 +115,7 @@ char *argv[];
for (i=1,pos=word_end_chars ; i < 256 ; i++) for (i=1,pos=word_end_chars ; i < 256 ; i++)
if (my_isspace(&my_charset_latin1,i)) if (my_isspace(&my_charset_latin1,i))
*pos++=i; *pos++= (char) i;
*pos=0; *pos=0;
if (!(replace=init_replace((char**) from.typelib.type_names, if (!(replace=init_replace((char**) from.typelib.type_names,
(char**) to.typelib.type_names, (char**) to.typelib.type_names,
...@@ -153,7 +150,7 @@ static int static_get_options(argc,argv) ...@@ -153,7 +150,7 @@ static int static_get_options(argc,argv)
register int *argc; register int *argc;
register char **argv[]; register char **argv[];
{ {
int help,version,opt; int help,version;
char *pos; char *pos;
silent=verbose=help=0; silent=verbose=help=0;
...@@ -162,7 +159,7 @@ register char **argv[]; ...@@ -162,7 +159,7 @@ register char **argv[];
while (*++pos) while (*++pos)
{ {
version=0; version=0;
switch((opt= *pos)) { switch((*pos)) {
case 's': case 's':
silent=1; silent=1;
break; break;
...@@ -249,7 +246,7 @@ POINTER_ARRAY *from_array,*to_array; ...@@ -249,7 +246,7 @@ POINTER_ARRAY *from_array,*to_array;
return 0; return 0;
} }
int insert_pointer_name(reg1 POINTER_ARRAY *pa,my_string name) static int insert_pointer_name(reg1 POINTER_ARRAY *pa,my_string name)
{ {
uint i,length,old_count; uint i,length,old_count;
byte *new_pos; byte *new_pos;
...@@ -323,8 +320,7 @@ int insert_pointer_name(reg1 POINTER_ARRAY *pa,my_string name) ...@@ -323,8 +320,7 @@ int insert_pointer_name(reg1 POINTER_ARRAY *pa,my_string name)
/* free pointer array */ /* free pointer array */
void free_pointer_array(pa) static void free_pointer_array(reg1 POINTER_ARRAY *pa)
reg1 POINTER_ARRAY *pa;
{ {
if (pa->typelib.count) if (pa->typelib.count)
{ {
...@@ -382,9 +378,9 @@ static void or_bits(REP_SET *to,REP_SET *from); ...@@ -382,9 +378,9 @@ static void or_bits(REP_SET *to,REP_SET *from);
static void copy_bits(REP_SET *to,REP_SET *from); static void copy_bits(REP_SET *to,REP_SET *from);
static int cmp_bits(REP_SET *set1,REP_SET *set2); static int cmp_bits(REP_SET *set1,REP_SET *set2);
static int get_next_bit(REP_SET *set,uint lastpos); static int get_next_bit(REP_SET *set,uint lastpos);
static int find_set(REP_SETS *sets,REP_SET *find); static short find_set(REP_SETS *sets,REP_SET *find);
static int find_found(FOUND_SET *found_set,uint table_offset, static short find_found(FOUND_SET *found_set,uint table_offset,
int found_offset); int found_offset);
static uint start_at_word(my_string pos); static uint start_at_word(my_string pos);
static uint end_of_word(my_string pos); static uint end_of_word(my_string pos);
static uint replace_len(my_string pos); static uint replace_len(my_string pos);
...@@ -394,11 +390,12 @@ static uint found_sets=0; ...@@ -394,11 +390,12 @@ static uint found_sets=0;
/* Init a replace structure for further calls */ /* Init a replace structure for further calls */
REPLACE *init_replace(my_string *from, my_string *to,uint count, static REPLACE *init_replace(my_string *from, my_string *to,uint count,
my_string word_end_chars) my_string word_end_chars)
{ {
uint i,j,states,set_nr,len,result_len,max_length,found_end,bits_set,bit_nr; uint i,j,states,set_nr,len,result_len,max_length,found_end,bits_set,bit_nr;
int used_sets,chr,default_state; int used_sets,chr;
short default_state;
char used_chars[LAST_CHAR_CODE],is_word_end[256]; char used_chars[LAST_CHAR_CODE],is_word_end[256];
my_string pos,to_pos,*to_array; my_string pos,to_pos,*to_array;
REP_SETS sets; REP_SETS sets;
...@@ -561,7 +558,7 @@ REPLACE *init_replace(my_string *from, my_string *to,uint count, ...@@ -561,7 +558,7 @@ REPLACE *init_replace(my_string *from, my_string *to,uint count,
for (chr= 0 ; chr < 256 ; chr++) for (chr= 0 ; chr < 256 ; chr++)
{ {
if (! used_chars[chr]) if (! used_chars[chr])
set->next[chr]= chr ? default_state : -1; set->next[chr]= (short) (chr ? default_state : -1);
else else
{ {
new_set=make_new_set(&sets); new_set=make_new_set(&sets);
...@@ -652,7 +649,7 @@ REPLACE *init_replace(my_string *from, my_string *to,uint count, ...@@ -652,7 +649,7 @@ REPLACE *init_replace(my_string *from, my_string *to,uint count,
for (i=1 ; i <= found_sets ; i++) for (i=1 ; i <= found_sets ; i++)
{ {
pos=from[found_set[i-1].table_offset]; pos=from[found_set[i-1].table_offset];
rep_str[i].found= !bcmp(pos,"\\^",3) ? 2 : 1; rep_str[i].found= (my_bool) (!bcmp(pos,"\\^",3) ? 2 : 1);
rep_str[i].replace_string=to_array[found_set[i-1].table_offset]; rep_str[i].replace_string=to_array[found_set[i-1].table_offset];
rep_str[i].to_offset=found_set[i-1].found_offset-start_at_word(pos); rep_str[i].to_offset=found_set[i-1].found_offset-start_at_word(pos);
rep_str[i].from_offset=found_set[i-1].found_offset-replace_len(pos)+ rep_str[i].from_offset=found_set[i-1].found_offset-replace_len(pos)+
...@@ -812,7 +809,7 @@ static int get_next_bit(REP_SET *set,uint lastpos) ...@@ -812,7 +809,7 @@ static int get_next_bit(REP_SET *set,uint lastpos)
free given set, else put in given set in sets and return it's free given set, else put in given set in sets and return it's
position */ position */
static int find_set(REP_SETS *sets,REP_SET *find) static short find_set(REP_SETS *sets,REP_SET *find)
{ {
uint i; uint i;
for (i=0 ; i < sets->count-1 ; i++) for (i=0 ; i < sets->count-1 ; i++)
...@@ -820,30 +817,33 @@ static int find_set(REP_SETS *sets,REP_SET *find) ...@@ -820,30 +817,33 @@ static int find_set(REP_SETS *sets,REP_SET *find)
if (!cmp_bits(sets->set+i,find)) if (!cmp_bits(sets->set+i,find))
{ {
free_last_set(sets); free_last_set(sets);
return i; return (short) i;
} }
} }
return i; /* return new postion */ return (short) i; /* return new postion */
} }
/* find if there is a found_set with same table_offset & found_offset
If there is return offset to it, else add new offset and return pos.
Pos returned is -offset-2 in found_set_structure because it's is
saved in set->next and set->next[] >= 0 points to next set and
set->next[] == -1 is reserved for end without replaces.
*/
static int find_found(FOUND_SET *found_set,uint table_offset, int found_offset) /*
find if there is a found_set with same table_offset & found_offset
If there is return offset to it, else add new offset and return pos.
Pos returned is -offset-2 in found_set_structure because it's is
saved in set->next and set->next[] >= 0 points to next set and
set->next[] == -1 is reserved for end without replaces.
*/
static short find_found(FOUND_SET *found_set,uint table_offset,
int found_offset)
{ {
int i; int i;
for (i=0 ; (uint) i < found_sets ; i++) for (i=0 ; (uint) i < found_sets ; i++)
if (found_set[i].table_offset == table_offset && if (found_set[i].table_offset == table_offset &&
found_set[i].found_offset == found_offset) found_set[i].found_offset == found_offset)
return -i-2; return (short) (-i-2);
found_set[i].table_offset=table_offset; found_set[i].table_offset=table_offset;
found_set[i].found_offset=found_offset; found_set[i].found_offset=found_offset;
found_sets++; found_sets++;
return -i-2; /* return new postion */ return (short) (-i-2); /* return new postion */
} }
/* Return 1 if regexp starts with \b or ends with \b*/ /* Return 1 if regexp starts with \b or ends with \b*/
...@@ -878,7 +878,8 @@ static uint replace_len(my_string str) ...@@ -878,7 +878,8 @@ static uint replace_len(my_string str)
/* The actual loop */ /* The actual loop */
uint replace_strings(REPLACE *rep, my_string *start,uint *max_length, my_string from) static uint replace_strings(REPLACE *rep, my_string *start,uint *max_length,
my_string from)
{ {
reg1 REPLACE *rep_pos; reg1 REPLACE *rep_pos;
reg2 REPLACE_STRING *rep_str; reg2 REPLACE_STRING *rep_str;
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
#ifndef yaSSL_BUFFER_HPP #ifndef yaSSL_BUFFER_HPP
#define yaSSL_BUFFER_HPP #define yaSSL_BUFFER_HPP
#include <cassert> // assert #include <assert.h> // assert
#include "yassl_error.hpp" // Error #include "yassl_error.hpp" // Error
#include "memory.hpp" // mySTL::auto_ptr #include "memory.hpp" // mySTL::auto_ptr
#include "algorithm.hpp" // mySTL::swap #include "algorithm.hpp" // mySTL::swap
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
#include "socket_wrapper.hpp" #include "socket_wrapper.hpp"
#ifdef YASSL_LOG #ifdef YASSL_LOG
#include <cstdio> #include <stdio.h>
#endif #endif
namespace yaSSL { namespace yaSSL {
......
...@@ -149,7 +149,7 @@ enum { /* X509 Constants */ ...@@ -149,7 +149,7 @@ enum { /* X509 Constants */
X509_V_ERR_CRL_SIGNATURE_FAILURE = 10, X509_V_ERR_CRL_SIGNATURE_FAILURE = 10,
X509_V_ERR_ERROR_IN_CRL_NEXT_UPDATE_FIELD = 11, X509_V_ERR_ERROR_IN_CRL_NEXT_UPDATE_FIELD = 11,
X509_V_ERR_CRL_HAS_EXPIRED = 12, X509_V_ERR_CRL_HAS_EXPIRED = 12,
X509_V_ERR_CERT_REVOKED = 13, X509_V_ERR_CERT_REVOKED = 13
}; };
...@@ -166,7 +166,7 @@ int ERR_GET_REASON(int); ...@@ -166,7 +166,7 @@ int ERR_GET_REASON(int);
enum { /* ERR Constants */ enum { /* ERR Constants */
ERR_TXT_STRING = 1, ERR_TXT_STRING = 1,
EVP_R_BAD_DECRYPT = 2, EVP_R_BAD_DECRYPT = 2
}; };
...@@ -263,8 +263,8 @@ enum { /* ssl Constants */ ...@@ -263,8 +263,8 @@ enum { /* ssl Constants */
SSL_UNKNOWN = -2, SSL_UNKNOWN = -2,
SSL_FATAL_ERROR = -1, SSL_FATAL_ERROR = -1,
SSL_NORMAL_SHUTDOWN = 0, SSL_NORMAL_SHUTDOWN = 0,
SSL_ERROR_NONE = 0, // for most functions SSL_ERROR_NONE = 0, /* for most functions */
SSL_FAILURE = 0, // for some functions SSL_FAILURE = 0, /* for some functions */
SSL_SUCCESS = 1, SSL_SUCCESS = 1,
SSL_FILETYPE_ASN1 = 10, SSL_FILETYPE_ASN1 = 10,
...@@ -320,7 +320,7 @@ enum { /* ssl Constants */ ...@@ -320,7 +320,7 @@ enum { /* ssl Constants */
SSL_ST_ACCEPT = 94, SSL_ST_ACCEPT = 94,
SSL_CB_ALERT = 95, SSL_CB_ALERT = 95,
SSL_CB_READ = 96, SSL_CB_READ = 96,
SSL_CB_HANDSHAKE_DONE = 97, SSL_CB_HANDSHAKE_DONE = 97
}; };
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
#ifndef yaSSL_SOCKET_WRAPPER_HPP #ifndef yaSSL_SOCKET_WRAPPER_HPP
#define yaSSL_SOCKET_WRAPPER_HPP #define yaSSL_SOCKET_WRAPPER_HPP
#include <cassert> #include <assert.h>
#ifdef WIN32 #ifdef WIN32
#include <winsock2.h> #include <winsock2.h>
......
...@@ -51,7 +51,7 @@ enum YasslError { ...@@ -51,7 +51,7 @@ enum YasslError {
verify_error = 112, verify_error = 112,
send_error = 113, send_error = 113,
receive_error = 114, receive_error = 114,
certificate_error = 115, certificate_error = 115
// 1000+ from TaoCrypt error.hpp // 1000+ from TaoCrypt error.hpp
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
#ifndef yaSSL_TYPES_HPP #ifndef yaSSL_TYPES_HPP
#define yaSSL_TYPES_HPP #define yaSSL_TYPES_HPP
#include<cstddef> #include <stddef.h>
namespace yaSSL { namespace yaSSL {
...@@ -129,7 +129,7 @@ enum PublicValueEncoding { implicit_encoding, explicit_encoding }; ...@@ -129,7 +129,7 @@ enum PublicValueEncoding { implicit_encoding, explicit_encoding };
enum ConnectionEnd { server_end, client_end }; enum ConnectionEnd { server_end, client_end };
enum AlertLevel { warning = 1, fatal = 2, }; enum AlertLevel { warning = 1, fatal = 2 };
...@@ -381,7 +381,7 @@ const char* const cipher_names[128] = ...@@ -381,7 +381,7 @@ const char* const cipher_names[128] =
"DES-CBC3-RMD", // TLS_RSA_WITH_3DES_EDE_CBC_RMD160 = 124 "DES-CBC3-RMD", // TLS_RSA_WITH_3DES_EDE_CBC_RMD160 = 124
"AES128-RMD", // TLS_RSA_WITH_AES_128_CBC_RMD160 = 125 "AES128-RMD", // TLS_RSA_WITH_AES_128_CBC_RMD160 = 125
"AES256-RMD", // TLS_RSA_WITH_AES_256_CBC_RMD160 = 126 "AES256-RMD", // TLS_RSA_WITH_AES_256_CBC_RMD160 = 126
null_str, // 127 null_str // 127
}; };
// fill with MD5 pad size since biggest required // fill with MD5 pad size since biggest required
......
...@@ -27,16 +27,28 @@ ...@@ -27,16 +27,28 @@
#ifndef mySTL_HELPERS_HPP #ifndef mySTL_HELPERS_HPP
#define mySTL_HELPERS_HPP #define mySTL_HELPERS_HPP
#include <cstdlib> #include <stdlib.h>
#ifdef __IBMCPP__
/*
Workaround for the lack of operator new(size_t, void*)
in IBM VA C++ 6.0
*/
struct Dummy {};
inline void *operator new(size_t size, Dummy *d) { return (void*) d; }
typedef Dummy *yassl_pointer;
#else
typedef void *yassl_pointer;
#endif
namespace mySTL { namespace mySTL {
template <typename T, typename T2> template <typename T, typename T2>
inline void construct(T* p, const T2& value) inline void construct(T* p, const T2& value)
{ {
new (static_cast<void*>(p)) T(value); new ((yassl_pointer) p) T(value);
} }
......
...@@ -38,6 +38,13 @@ namespace mySTL { ...@@ -38,6 +38,13 @@ namespace mySTL {
template<typename T> template<typename T>
class list { class list {
#ifdef __SUNPRO_CC
/*
Sun Forte 7 C++ v. 5.4 needs class 'node' be public to be visible to
the nested class 'iterator' (a non-standard behaviour).
*/
public:
#endif
struct node { struct node {
node(T t) : prev_(0), next_(0), value_(t) {} node(T t) : prev_(0), next_(0), value_(t) {}
......
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
#define mySTL_STDEXCEPT_HPP #define mySTL_STDEXCEPT_HPP
#include <cstring> // strncpy #include <string.h> // strncpy
namespace mySTL { namespace mySTL {
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
#include "helpers.hpp" // construct, destory, fill, etc. #include "helpers.hpp" // construct, destory, fill, etc.
#include "algorithm.hpp" // swap #include "algorithm.hpp" // swap
#include <new> // ::operator new and delete, placement too #include <new> // ::operator new and delete, placement too
#include <cassert> // assert #include <assert.h> // assert
namespace mySTL { namespace mySTL {
......
...@@ -273,8 +273,8 @@ int CertManager::SetPrivateKey(const x509& key) ...@@ -273,8 +273,8 @@ int CertManager::SetPrivateKey(const x509& key)
privateKey_.assign(key.get_buffer(), key.get_length()); privateKey_.assign(key.get_buffer(), key.get_length());
// set key type // set key type
if (x509* cert = list_.front()) { if (x509* cert509 = list_.front()) {
TaoCrypt::Source source(cert->get_buffer(), cert->get_length()); TaoCrypt::Source source(cert509->get_buffer(), cert509->get_length());
TaoCrypt::CertDecoder cert(source, false); TaoCrypt::CertDecoder cert(source, false);
cert.DecodeToKey(); cert.DecodeToKey();
if (int err = cert.GetError().What()) if (int err = cert.GetError().What())
......
/*
To make libtool always use a C++ linker when compiling with yaSSL we need
to add a dummy C++ file to the source list.
*/
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
#include "openssl/ssl.h" #include "openssl/ssl.h"
#include "handshake.hpp" #include "handshake.hpp"
#include "yassl_int.hpp" #include "yassl_int.hpp"
#include <cstdio> #include <stdio.h>
namespace yaSSL { namespace yaSSL {
......
...@@ -79,7 +79,7 @@ enum ASNIdFlag ...@@ -79,7 +79,7 @@ enum ASNIdFlag
enum DNTags enum DNTags
{ {
COMMON_NAME = 0x03, COMMON_NAME = 0x03
}; };
...@@ -92,7 +92,7 @@ enum Constants ...@@ -92,7 +92,7 @@ enum Constants
MAX_SEQ_SZ = 5, // enum(seq|con) + length(4) MAX_SEQ_SZ = 5, // enum(seq|con) + length(4)
MAX_ALGO_SIZE = 9, MAX_ALGO_SIZE = 9,
MAX_DIGEST_SZ = 25, // SHA + enum(Bit or Octet) + length(4) MAX_DIGEST_SZ = 25, // SHA + enum(Bit or Octet) + length(4)
DSA_SIG_SZ = 40, DSA_SIG_SZ = 40
}; };
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
#include "stdexcept.hpp" // mySTL::runtime_error #include "stdexcept.hpp" // mySTL::runtime_error
#include "misc.hpp" #include "misc.hpp"
#include <string.h> // memcpy #include <string.h> // memcpy
#include <cstddef> // ptrdiff_t #include <stddef.h> // ptrdiff_t
#if defined(_MSC_VER) && defined(_CRTAPI1) #if defined(_MSC_VER) && defined(_CRTAPI1)
...@@ -49,11 +49,7 @@ class AllocatorBase ...@@ -49,11 +49,7 @@ class AllocatorBase
public: public:
typedef T value_type; typedef T value_type;
typedef size_t size_type; typedef size_t size_type;
#ifdef TAOCRYPT_MSVCRT6
typedef ptrdiff_t difference_type; typedef ptrdiff_t difference_type;
#else
typedef std::ptrdiff_t difference_type;
#endif
typedef T* pointer; typedef T* pointer;
typedef const T* const_pointer; typedef const T* const_pointer;
typedef T& reference; typedef T& reference;
......
...@@ -65,7 +65,7 @@ UNKOWN_HASH_E = 1034, // "unknown hash OID" ...@@ -65,7 +65,7 @@ UNKOWN_HASH_E = 1034, // "unknown hash OID"
DSA_SZ_E = 1035, // "bad DSA r or s size" DSA_SZ_E = 1035, // "bad DSA r or s size"
BEFORE_DATE_E = 1036, // "before date in the future" BEFORE_DATE_E = 1036, // "before date in the future"
AFTER_DATE_E = 1037, // "after date in the past" AFTER_DATE_E = 1037, // "after date in the past"
SIG_CONFIRM_E = 1038, // "bad signature confirmation" SIG_CONFIRM_E = 1038 // "bad signature confirmation"
}; };
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
#include "misc.hpp" #include "misc.hpp"
#include "block.hpp" #include "block.hpp"
#include "error.hpp" #include "error.hpp"
#include <cstdio> #include <stdio.h>
namespace TaoCrypt { namespace TaoCrypt {
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
#include "block.hpp" #include "block.hpp"
#include "random.hpp" #include "random.hpp"
#include "file.hpp" #include "file.hpp"
#include <cstring> #include <string.h>
#include "algorithm.hpp" // mySTL::swap #include "algorithm.hpp" // mySTL::swap
......
...@@ -59,7 +59,7 @@ typedef unsigned char byte; ...@@ -59,7 +59,7 @@ typedef unsigned char byte;
typedef unsigned short word16; typedef unsigned short word16;
typedef unsigned int word32; typedef unsigned int word32;
#if defined(__GNUC__) || defined(__MWERKS__) #if defined(__GNUC__) || defined(__MWERKS__) || defined(_LONGLONG_TYPE)
#define WORD64_AVAILABLE #define WORD64_AVAILABLE
typedef unsigned long long word64; typedef unsigned long long word64;
#define W64LIT(x) x##LL #define W64LIT(x) x##LL
...@@ -79,8 +79,10 @@ typedef unsigned int word32; ...@@ -79,8 +79,10 @@ typedef unsigned int word32;
typedef word32 lword; typedef word32 lword;
#endif #endif
// FIXME the !defined(__sun) is a temporarely solution until asm for
// __x86_64__ and Solaris is written
#if defined(__alpha__) || defined(__ia64__) || defined(_ARCH_PPC64) || \ #if defined(__alpha__) || defined(__ia64__) || defined(_ARCH_PPC64) || \
defined(__x86_64__) || defined(__mips64) defined(__mips64) || (defined(__x86_64__) && !defined(__sun))
// These platforms have 64-bit CPU registers. Unfortunately most C++ compilers // These platforms have 64-bit CPU registers. Unfortunately most C++ compilers
// don't allow any way to access the 64-bit by 64-bit multiply instruction // don't allow any way to access the 64-bit by 64-bit multiply instruction
// without using assembly, so in order to use word64 as word, the assembly // without using assembly, so in order to use word64 as word, the assembly
...@@ -97,7 +99,7 @@ typedef unsigned int word32; ...@@ -97,7 +99,7 @@ typedef unsigned int word32;
typedef word32 word; typedef word32 word;
typedef word64 dword; typedef word64 dword;
#else #else
typedef word8 hword; typedef byte hword;
typedef word16 word; typedef word16 word;
typedef word32 dword; typedef word32 dword;
#endif #endif
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
#if __GNUC__ > 2 #if __GNUC__ > 2
#include <cstdlib> #include <stdlib.h>
static void* operator new (size_t sz) static void* operator new (size_t sz)
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
#include "runtime.hpp" #include "runtime.hpp"
#include "dh.hpp" #include "dh.hpp"
#include "asn.hpp" #include "asn.hpp"
#include <cmath> #include <math.h>
namespace TaoCrypt { namespace TaoCrypt {
......
...@@ -96,6 +96,7 @@ extern const char *client_errors[]; /* Error messages */ ...@@ -96,6 +96,7 @@ extern const char *client_errors[]; /* Error messages */
#define CR_NO_DATA 2051 #define CR_NO_DATA 2051
#define CR_NO_STMT_METADATA 2052 #define CR_NO_STMT_METADATA 2052
#define CR_NO_RESULT_SET 2053 #define CR_NO_RESULT_SET 2053
#define CR_ERROR_LAST /*Copy last error nr:*/ 2053 #define CR_NOT_IMPLEMENTED 2054
#define CR_ERROR_LAST /*Copy last error nr:*/ 2054
/* Add error numbers before CR_ERROR_LAST and change it accordingly. */ /* Add error numbers before CR_ERROR_LAST and change it accordingly. */
...@@ -39,9 +39,9 @@ extern void _db_pargs_(uint _line_,const char *keyword); ...@@ -39,9 +39,9 @@ extern void _db_pargs_(uint _line_,const char *keyword);
extern void _db_doprnt_ _VARARGS((const char *format,...)); extern void _db_doprnt_ _VARARGS((const char *format,...));
extern void _db_dump_(uint _line_,const char *keyword,const char *memory, extern void _db_dump_(uint _line_,const char *keyword,const char *memory,
uint length); uint length);
extern void _db_output_(); extern void _db_output_(uint flag);
extern void _db_lock_file(); extern void _db_lock_file(void);
extern void _db_unlock_file(); extern void _db_unlock_file(void);
#define DBUG_ENTER(a) const char *_db_func_, *_db_file_; uint _db_level_; \ #define DBUG_ENTER(a) const char *_db_func_, *_db_file_; uint _db_level_; \
char **_db_framep_; \ char **_db_framep_; \
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
#endif /* __CYGWIN__ */ #endif /* __CYGWIN__ */
/* Determine when to use "#pragma interface" */ /* Determine when to use "#pragma interface" */
#if !defined(__CYGWIN__) && !defined(__ICC) && defined(__GNUC__) && (__GNUC__ < 3) #if !defined(__CYGWIN__) && !defined(__INTEL_COMPILER) && defined(__GNUC__) && (__GNUC__ < 3)
#define USE_PRAGMA_INTERFACE #define USE_PRAGMA_INTERFACE
#endif #endif
......
...@@ -778,15 +778,13 @@ extern void reset_root_defaults(MEM_ROOT *mem_root, uint block_size, ...@@ -778,15 +778,13 @@ extern void reset_root_defaults(MEM_ROOT *mem_root, uint block_size,
extern char *strdup_root(MEM_ROOT *root,const char *str); extern char *strdup_root(MEM_ROOT *root,const char *str);
extern char *strmake_root(MEM_ROOT *root,const char *str,uint len); extern char *strmake_root(MEM_ROOT *root,const char *str,uint len);
extern char *memdup_root(MEM_ROOT *root,const char *str,uint len); extern char *memdup_root(MEM_ROOT *root,const char *str,uint len);
extern int my_correct_defaults_file(const char *file_location,
const char *option,
const char *option_value,
const char *section_name,
int remove_option);
extern void get_defaults_files(int argc, char **argv, extern void get_defaults_files(int argc, char **argv,
char **defaults, char **extra_defaults); char **defaults, char **extra_defaults);
extern int load_defaults(const char *conf_file, const char **groups, extern int load_defaults(const char *conf_file, const char **groups,
int *argc, char ***argv); int *argc, char ***argv);
extern int modify_defaults_file(const char *file_location, const char *option,
const char *option_value,
const char *section_name, int remove_option);
extern int my_search_option_files(const char *conf_file, int *argc, extern int my_search_option_files(const char *conf_file, int *argc,
char ***argv, uint *args_used, char ***argv, uint *args_used,
Process_option_func func, void *func_ctx); Process_option_func func, void *func_ctx);
......
...@@ -664,6 +664,7 @@ typedef struct st_mysql_stmt ...@@ -664,6 +664,7 @@ typedef struct st_mysql_stmt
unsigned char **row); unsigned char **row);
unsigned long stmt_id; /* Id for prepared statement */ unsigned long stmt_id; /* Id for prepared statement */
unsigned long flags; /* i.e. type of cursor to open */ unsigned long flags; /* i.e. type of cursor to open */
unsigned long prefetch_rows; /* number of rows per one COM_FETCH */
/* /*
Copied from mysql->server_status after execute/fetch to know Copied from mysql->server_status after execute/fetch to know
server-side cursor status for this statement. server-side cursor status for this statement.
...@@ -702,7 +703,12 @@ enum enum_stmt_attr_type ...@@ -702,7 +703,12 @@ enum enum_stmt_attr_type
unsigned long with combination of cursor flags (read only, for update, unsigned long with combination of cursor flags (read only, for update,
etc) etc)
*/ */
STMT_ATTR_CURSOR_TYPE STMT_ATTR_CURSOR_TYPE,
/*
Amount of rows to retrieve from server per one fetch if using cursors.
Accepts unsigned long attribute in the range 1 - ulong_max
*/
STMT_ATTR_PREFETCH_ROWS
}; };
......
...@@ -417,6 +417,9 @@ const char *mysql_errno_to_sqlstate(unsigned int mysql_errno); ...@@ -417,6 +417,9 @@ const char *mysql_errno_to_sqlstate(unsigned int mysql_errno);
/* Some other useful functions */ /* Some other useful functions */
my_bool my_init(void); my_bool my_init(void);
extern int modify_defaults_file(const char *file_location, const char *option,
const char *option_value,
const char *section_name, int remove_option);
int load_defaults(const char *conf_file, const char **groups, int load_defaults(const char *conf_file, const char **groups,
int *argc, char ***argv); int *argc, char ***argv);
my_bool my_thread_init(void); my_bool my_thread_init(void);
......
This diff is collapsed.
...@@ -61,7 +61,8 @@ mysysobjects1 = my_init.lo my_static.lo my_malloc.lo my_realloc.lo \ ...@@ -61,7 +61,8 @@ mysysobjects1 = my_init.lo my_static.lo my_malloc.lo my_realloc.lo \
mf_format.lo mf_path.lo mf_unixpath.lo my_fopen.lo \ mf_format.lo mf_path.lo mf_unixpath.lo my_fopen.lo \
my_symlink.lo my_fstream.lo \ my_symlink.lo my_fstream.lo \
mf_loadpath.lo my_pthread.lo my_thr_init.lo \ mf_loadpath.lo my_pthread.lo my_thr_init.lo \
thr_mutex.lo mulalloc.lo string.lo default.lo \ thr_mutex.lo mulalloc.lo string.lo \
default.lo default_modify.lo \
my_compress.lo array.lo my_once.lo list.lo my_net.lo \ my_compress.lo array.lo my_once.lo list.lo my_net.lo \
charset.lo charset-def.lo hash.lo mf_iocache.lo \ charset.lo charset-def.lo hash.lo mf_iocache.lo \
mf_iocache2.lo my_seek.lo my_sleep.lo \ mf_iocache2.lo my_seek.lo my_sleep.lo \
......
...@@ -81,6 +81,7 @@ const char *client_errors[]= ...@@ -81,6 +81,7 @@ const char *client_errors[]=
"Attempt to read column without prior row fetch", "Attempt to read column without prior row fetch",
"Prepared statement contains no metadata", "Prepared statement contains no metadata",
"Attempt to read a row while there is no result set associated with the statement", "Attempt to read a row while there is no result set associated with the statement",
"This feature is not implemented yet",
"" ""
}; };
...@@ -143,6 +144,7 @@ const char *client_errors[]= ...@@ -143,6 +144,7 @@ const char *client_errors[]=
"Attempt to read column without prior row fetch", "Attempt to read column without prior row fetch",
"Prepared statement contains no metadata", "Prepared statement contains no metadata",
"Attempt to read a row while there is no result set associated with the statement", "Attempt to read a row while there is no result set associated with the statement",
"This feature is not implemented yet",
"" ""
}; };
...@@ -203,6 +205,7 @@ const char *client_errors[]= ...@@ -203,6 +205,7 @@ const char *client_errors[]=
"Attempt to read column without prior row fetch", "Attempt to read column without prior row fetch",
"Prepared statement contains no metadata", "Prepared statement contains no metadata",
"Attempt to read a row while there is no result set associated with the statement", "Attempt to read a row while there is no result set associated with the statement",
"This feature is not implemented yet",
"" ""
}; };
#endif #endif
......
This diff is collapsed.
LIBRARY LIBMYSQL LIBRARY LIBMYSQL
DESCRIPTION 'MySQL 4.1 Client Library' DESCRIPTION 'MySQL 5.0 Client Library'
VERSION 6.0 VERSION 6.0
EXPORTS EXPORTS
_dig_vec_lower _dig_vec_lower
...@@ -150,6 +150,4 @@ EXPORTS ...@@ -150,6 +150,4 @@ EXPORTS
mysql_server_end mysql_server_end
mysql_set_character_set mysql_set_character_set
get_defaults_files get_defaults_files
get_charset_by_csname modify_defaults_file
get_charsets_dir
charsets_dir
...@@ -160,3 +160,4 @@ EXPORTS ...@@ -160,3 +160,4 @@ EXPORTS
get_defaults_files get_defaults_files
my_charset_bin my_charset_bin
my_charset_same my_charset_same
modify_defaults_file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
eval select "Outfile OK" into outfile "$MYSQL_TEST_DIR/var/tmp/outfile.test";
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
load_file(concat(@tmpdir,"/outfile.test"))
Outfile OK
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment