summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/ac-macros/compiler_flag.m42
-rw-r--r--config/ac-macros/ha_archive.m429
-rw-r--r--config/ac-macros/ha_berkeley.m4267
-rw-r--r--config/ac-macros/ha_blackhole.m429
-rw-r--r--config/ac-macros/ha_example.m430
-rw-r--r--config/ac-macros/ha_federated.m429
-rw-r--r--config/ac-macros/ha_innodb.m477
-rw-r--r--config/ac-macros/ha_ndbcluster.m4275
-rw-r--r--config/ac-macros/ha_tina.m429
-rw-r--r--config/ac-macros/misc.m4145
-rw-r--r--config/ac-macros/openssl.m4138
-rw-r--r--config/ac-macros/plugins.m4815
-rw-r--r--config/ac-macros/ssl.m4210
-rw-r--r--config/ac-macros/yassl.m445
-rw-r--r--config/ac-macros/zlib.m45
15 files changed, 1278 insertions, 847 deletions
diff --git a/config/ac-macros/compiler_flag.m4 b/config/ac-macros/compiler_flag.m4
index 88097c7a62e..ce2ce6cbdfa 100644
--- a/config/ac-macros/compiler_flag.m4
+++ b/config/ac-macros/compiler_flag.m4
@@ -7,7 +7,7 @@ AC_DEFUN([AC_SYS_COMPILER_FLAG],
AC_CACHE_VAL(mysql_cv_option_$2,
[
CFLAGS="[$]OLD_CFLAGS $1"
- AC_TRY_RUN([int main(){exit(0);}],mysql_cv_option_$2=yes,mysql_cv_option_$2=no,mysql_cv_option_$2=no)
+ AC_TRY_LINK([int main(){exit(0);}],mysql_cv_option_$2=yes,mysql_cv_option_$2=no,mysql_cv_option_$2=no)
])
CFLAGS="[$]OLD_CFLAGS"
diff --git a/config/ac-macros/ha_archive.m4 b/config/ac-macros/ha_archive.m4
deleted file mode 100644
index 2d2558ea600..00000000000
--- a/config/ac-macros/ha_archive.m4
+++ /dev/null
@@ -1,29 +0,0 @@
-dnl ---------------------------------------------------------------------------
-dnl Macro: MYSQL_CHECK_ARCHIVEDB
-dnl Sets HAVE_ARCHIVE_DB if --with-archive-storage-engine is used
-dnl ---------------------------------------------------------------------------
-AC_DEFUN([MYSQL_CHECK_ARCHIVEDB], [
- AC_ARG_WITH([archive-storage-engine],
- [
- --with-archive-storage-engine
- Enable the Archive Storage Engine],
- [archivedb="$withval"],
- [archivedb=no])
- AC_MSG_CHECKING([for archive storage engine])
-
- case "$archivedb" in
- yes )
- AC_DEFINE([HAVE_ARCHIVE_DB], [1], [Builds Archive Storage Engine])
- AC_MSG_RESULT([yes])
- [archivedb=yes]
- ;;
- * )
- AC_MSG_RESULT([no])
- [archivedb=no]
- ;;
- esac
-
-])
-dnl ---------------------------------------------------------------------------
-dnl END OF MYSQL_CHECK_ARCHIVE SECTION
-dnl ---------------------------------------------------------------------------
diff --git a/config/ac-macros/ha_berkeley.m4 b/config/ac-macros/ha_berkeley.m4
deleted file mode 100644
index 82786436720..00000000000
--- a/config/ac-macros/ha_berkeley.m4
+++ /dev/null
@@ -1,267 +0,0 @@
-dnl ---------------------------------------------------------------------------
-dnl Macro: MYSQL_CHECK_BDB
-dnl Sets HAVE_BERKELEY_DB if inst library is found
-dnl Makes sure db version is correct.
-dnl Looks in $srcdir for Berkeley distribution if not told otherwise
-dnl ---------------------------------------------------------------------------
-
-AC_DEFUN([MYSQL_CHECK_BDB], [
- AC_ARG_WITH([berkeley-db],
- [
- --with-berkeley-db[=DIR]
- Use BerkeleyDB located in DIR],
- [bdb="$withval"],
- [bdb=no])
-
- AC_ARG_WITH([berkeley-db-includes],
- [
- --with-berkeley-db-includes=DIR
- Find Berkeley DB headers in DIR],
- [bdb_includes="$withval"],
- [bdb_includes=default])
-
- AC_ARG_WITH([berkeley-db-libs],
- [
- --with-berkeley-db-libs=DIR
- Find Berkeley DB libraries in DIR],
- [bdb_libs="$withval"],
- [bdb_libs=default])
-
- AC_MSG_CHECKING([for BerkeleyDB])
-
-dnl SORT OUT THE SUPPLIED ARGUMENTS TO DETERMINE WHAT TO DO
-dnl echo "DBG1: bdb='$bdb'; incl='$bdb_includes'; lib='$bdb_libs'"
- have_berkeley_db=no
- case "$bdb" in
- no )
- mode=no
- AC_MSG_RESULT([no])
- ;;
- yes | default )
- case "$bdb_includes---$bdb_libs" in
- default---default )
- mode=search-$bdb
- AC_MSG_RESULT([searching...])
- ;;
- default---* | *---default | yes---* | *---yes )
- AC_MSG_ERROR([if either 'includes' or 'libs' is specified, both must be specified])
- ;;
- * )
- mode=supplied-two
- AC_MSG_RESULT([supplied])
- ;;
- esac
- ;;
- * )
- mode=supplied-one
- AC_MSG_RESULT([supplied])
- ;;
- esac
-
-dnl echo "DBG2: [$mode] bdb='$bdb'; incl='$bdb_includes'; lib='$bdb_libs'"
-
- case $mode in
- no )
- bdb_includes=
- bdb_libs=
- bdb_libs_with_path=
- ;;
- supplied-two )
- MYSQL_CHECK_INSTALLED_BDB([$bdb_includes], [$bdb_libs])
- case $bdb_dir_ok in
- installed ) mode=yes ;;
- * ) AC_MSG_ERROR([didn't find valid BerkeleyDB: $bdb_dir_ok]) ;;
- esac
- ;;
- supplied-one )
- MYSQL_CHECK_BDB_DIR([$bdb])
- case $bdb_dir_ok in
- source ) mode=compile ;;
- installed ) mode=yes ;;
- * ) AC_MSG_ERROR([didn't find valid BerkeleyDB: $bdb_dir_ok]) ;;
- esac
- ;;
- search-* )
- MYSQL_SEARCH_FOR_BDB
- case $bdb_dir_ok in
- source ) mode=compile ;;
- installed ) mode=yes ;;
- * )
- # not found
- case $mode in
- *-yes ) AC_MSG_ERROR([no suitable BerkeleyDB found]) ;;
- * ) mode=no ;;
- esac
- bdb_includes=
- bdb_libs=
- bdb_libs_with_path=
- ;;
- esac
- ;;
- *)
- AC_MSG_ERROR([impossible case condition '$mode': please report this to bugs@lists.mysql.com])
- ;;
- esac
-
-dnl echo "DBG3: [$mode] bdb='$bdb'; incl='$bdb_includes'; lib='$bdb_libs'"
- case $mode in
- no )
- AC_MSG_RESULT([Not using Berkeley DB])
- ;;
- yes )
- have_berkeley_db="yes"
- AC_MSG_RESULT([Using Berkeley DB in '$bdb_includes'])
- ;;
- compile )
- have_berkeley_db="$bdb"
- AC_MSG_RESULT([Compiling Berekeley DB in '$have_berkeley_db'])
- ;;
- * )
- AC_MSG_ERROR([impossible case condition '$mode': please report this to bugs@lists.mysql.com])
- ;;
- esac
-
- AC_SUBST(bdb_includes)
- AC_SUBST(bdb_libs)
- AC_SUBST(bdb_libs_with_path)
-])
-
-AC_DEFUN([MYSQL_CHECK_INSTALLED_BDB], [
-dnl echo ["MYSQL_CHECK_INSTALLED_BDB ($1) ($2)"]
- inc="$1"
- lib="$2"
- if test -f "$inc/db.h"
- then
- MYSQL_CHECK_BDB_VERSION([$inc/db.h],
- [.*#define[ ]*], [[ ][ ]*])
-
- if test X"$bdb_version_ok" = Xyes; then
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="-L$lib $LDFLAGS"
- AC_CHECK_LIB(db,db_env_create, [
- bdb_dir_ok=installed
- MYSQL_TOP_BUILDDIR([inc])
- MYSQL_TOP_BUILDDIR([lib])
- bdb_includes="-I$inc"
- bdb_libs="-L$lib -ldb"
- bdb_libs_with_path="$lib/libdb.a"
- ])
- LDFLAGS="$save_LDFLAGS"
- else
- bdb_dir_ok="$bdb_version_ok"
- fi
- else
- bdb_dir_ok="no db.h file in '$inc'"
- fi
-])
-
-AC_DEFUN([MYSQL_CHECK_BDB_DIR], [
-dnl ([$bdb])
-dnl echo ["MYSQL_CHECK_BDB_DIR ($1)"]
- dir="$1"
-
- MYSQL_CHECK_INSTALLED_BDB([$dir/include], [$dir/lib])
-
- if test X"$bdb_dir_ok" != Xinstalled; then
- # test to see if it's a source dir
- rel="$dir/dist/RELEASE"
- if test -f "$rel"; then
- MYSQL_CHECK_BDB_VERSION([$rel], [], [=])
- if test X"$bdb_version_ok" = Xyes; then
- bdb_dir_ok=source
- bdb="$dir"
- MYSQL_TOP_BUILDDIR([dir])
- bdb_includes="-I$dir/build_unix"
- bdb_libs="-L$dir/build_unix -ldb"
- bdb_libs_with_path="$dir/build_unix/libdb.a"
- else
- bdb_dir_ok="$bdb_version_ok"
- fi
- else
- bdb_dir_ok="'$dir' doesn't look like a BDB directory ($bdb_dir_ok)"
- fi
- fi
-])
-
-AC_DEFUN([MYSQL_SEARCH_FOR_BDB], [
-dnl echo ["MYSQL_SEARCH_FOR_BDB"]
- bdb_dir_ok="no BerkeleyDB found"
-
- for test_dir in $srcdir/bdb $srcdir/db-*.*.* /usr/local/BerkeleyDB*; do
-dnl echo "-----------> Looking at ($test_dir; `cd $test_dir && pwd`)"
- MYSQL_CHECK_BDB_DIR([$test_dir])
- if test X"$bdb_dir_ok" = Xsource || test X"$bdb_dir_ok" = Xinstalled; then
-dnl echo "-----------> Found it ($bdb), ($srcdir)"
-dnl This is needed so that 'make distcheck' works properly (VPATH build).
-dnl VPATH build won't work if bdb is not under the source tree; but in
-dnl that case, hopefully people will just make and install inside the
-dnl tree, or install BDB first, and then use the installed version.
- case "$bdb" in
- "$srcdir/"* ) bdb=`echo "$bdb" | sed -e "s,^$srcdir/,,"` ;;
- esac
- break
- fi
- done
-])
-
-dnl MYSQL_CHECK_BDB_VERSION takes 3 arguments:
-dnl 1) the file to look in
-dnl 2) the search pattern before DB_VERSION_XXX
-dnl 3) the search pattern between DB_VERSION_XXX and the number
-dnl It assumes that the number is the last thing on the line
-AC_DEFUN([MYSQL_CHECK_BDB_VERSION], [
- db_major=`sed -e '/^[$2]DB_VERSION_MAJOR[$3]/ !d' -e 's///' [$1]`
- db_minor=`sed -e '/^[$2]DB_VERSION_MINOR[$3]/ !d' -e 's///' [$1]`
- db_patch=`sed -e '/^[$2]DB_VERSION_PATCH[$3]/ !d' -e 's///' [$1]`
- test -z "$db_major" && db_major=0
- test -z "$db_minor" && db_minor=0
- test -z "$db_patch" && db_patch=0
-
- # This is ugly, but about as good as it can get
-# mysql_bdb=
-# if test $db_major -eq 3 && test $db_minor -eq 2 && test $db_patch -eq 3
-# then
-# mysql_bdb=h
-# elif test $db_major -eq 3 && test $db_minor -eq 2 && test $db_patch -eq 9
-# then
-# want_bdb_version="3.2.9a" # hopefully this will stay up-to-date
-# mysql_bdb=a
-# fi
-
-dnl RAM:
-want_bdb_version="4.1.24"
-bdb_version_ok=yes
-
-# if test -n "$mysql_bdb" && \
-# grep "DB_VERSION_STRING.*:.*$mysql_bdb: " [$1] > /dev/null
-# then
-# bdb_version_ok=yes
-# else
-# bdb_version_ok="invalid version $db_major.$db_minor.$db_patch"
-# bdb_version_ok="$bdb_version_ok (must be version 3.2.3h or $want_bdb_version)"
-# fi
-])
-
-AC_DEFUN([MYSQL_TOP_BUILDDIR], [
- # Remove trailing "./" if any
- [$1]=`echo $[$1] | sed -e 's,^\./,,'`
- case "$[$1]" in
- "bdb" | "$srcdir/bdb" | "$top_srcdir/bdb" | "$abs_top_srcdir/bdb" )
- # If BDB is under the source directory, we need to look under the
- # build directory for bdb/build_unix.
- [$1]="\$(top_builddir)/bdb"
- ;;
- /* ) ;; # Other absolute path is assume to be external BDB directory
- * )
- AC_MSG_ERROR([The BDB directory must be directly under the MySQL source directory, or be specified using the full path. ('$srcdir'; '$[$1]')])
- ;;
- esac
- if test X"$[$1]" != X"/"
- then
- [$1]=`echo $[$1] | sed -e 's,/$,,'`
- fi
-])
-
-dnl ---------------------------------------------------------------------------
-dnl END OF MYSQL_CHECK_BDB SECTION
-dnl ---------------------------------------------------------------------------
diff --git a/config/ac-macros/ha_blackhole.m4 b/config/ac-macros/ha_blackhole.m4
deleted file mode 100644
index cc4d360f5a8..00000000000
--- a/config/ac-macros/ha_blackhole.m4
+++ /dev/null
@@ -1,29 +0,0 @@
-dnl ---------------------------------------------------------------------------
-dnl Macro: MYSQL_CHECK_BLACKHOLEDB
-dnl Sets HAVE_BLACKHOLE_DB if --with-blackhole-storage-engine is used
-dnl ---------------------------------------------------------------------------
-AC_DEFUN([MYSQL_CHECK_BLACKHOLEDB], [
- AC_ARG_WITH([blackhole-storage-engine],
- [
- --with-blackhole-storage-engine
- Enable the Blackhole Storage Engine],
- [blackholedb="$withval"],
- [blackholedb=no])
- AC_MSG_CHECKING([for blackhole storage engine])
-
- case "$blackholedb" in
- yes )
- AC_DEFINE([HAVE_BLACKHOLE_DB], [1], [Builds Blackhole Storage Engine])
- AC_MSG_RESULT([yes])
- [blackholedb=yes]
- ;;
- * )
- AC_MSG_RESULT([no])
- [blackholedb=no]
- ;;
- esac
-
-])
-dnl ---------------------------------------------------------------------------
-dnl END OF MYSQL_CHECK_BLACKHOLE SECTION
-dnl ---------------------------------------------------------------------------
diff --git a/config/ac-macros/ha_example.m4 b/config/ac-macros/ha_example.m4
deleted file mode 100644
index f8067931ce6..00000000000
--- a/config/ac-macros/ha_example.m4
+++ /dev/null
@@ -1,30 +0,0 @@
-dnl ---------------------------------------------------------------------------
-dnl Macro: MYSQL_CHECK_EXAMPLEDB
-dnl Sets HAVE_EXAMPLE_DB if --with-example-storage-engine is used
-dnl ---------------------------------------------------------------------------
-AC_DEFUN([MYSQL_CHECK_EXAMPLEDB], [
- AC_ARG_WITH([example-storage-engine],
- [
- --with-example-storage-engine
- Enable the Example Storage Engine],
- [exampledb="$withval"],
- [exampledb=no])
- AC_MSG_CHECKING([for example storage engine])
-
- case "$exampledb" in
- yes )
- AC_DEFINE([HAVE_EXAMPLE_DB], [1], [Builds Example DB])
- AC_MSG_RESULT([yes])
- [exampledb=yes]
- ;;
- * )
- AC_MSG_RESULT([no])
- [exampledb=no]
- ;;
- esac
-
-])
-dnl ---------------------------------------------------------------------------
-dnl END OF MYSQL_CHECK_EXAMPLE SECTION
-dnl ---------------------------------------------------------------------------
-
diff --git a/config/ac-macros/ha_federated.m4 b/config/ac-macros/ha_federated.m4
deleted file mode 100644
index 5c991f31666..00000000000
--- a/config/ac-macros/ha_federated.m4
+++ /dev/null
@@ -1,29 +0,0 @@
-dnl ---------------------------------------------------------------------------
-dnl Macro: MYSQL_CHECK_FEDERATED
-dnl Sets HAVE_FEDERATED if --with-federated-storage-engine is used
-dnl ---------------------------------------------------------------------------
-AC_DEFUN([MYSQL_CHECK_FEDERATED], [
- AC_ARG_WITH([federated-storage-engine],
- [
- --with-federated-storage-engine
- Enable the MySQL Federated Storage Engine],
- [federateddb="$withval"],
- [federateddb=no])
- AC_MSG_CHECKING([for MySQL federated storage engine])
-
- case "$federateddb" in
- yes )
- AC_DEFINE([HAVE_FEDERATED_DB], [1], [Define to enable Federated Handler])
- AC_MSG_RESULT([yes])
- [federateddb=yes]
- ;;
- * )
- AC_MSG_RESULT([no])
- [federateddb=no]
- ;;
- esac
-
-])
-dnl ---------------------------------------------------------------------------
-dnl END OF MYSQL_CHECK_FEDERATED SECTION
-dnl ---------------------------------------------------------------------------
diff --git a/config/ac-macros/ha_innodb.m4 b/config/ac-macros/ha_innodb.m4
deleted file mode 100644
index f670eeb9751..00000000000
--- a/config/ac-macros/ha_innodb.m4
+++ /dev/null
@@ -1,77 +0,0 @@
-dnl ---------------------------------------------------------------------------
-dnl Macro: MYSQL_CHECK_INNODB
-dnl Sets HAVE_INNOBASE_DB if --with-innodb is used
-dnl ---------------------------------------------------------------------------
-
-AC_DEFUN([MYSQL_CHECK_INNODB], [
- AC_ARG_WITH([innodb],
- [
- --without-innodb Do not include the InnoDB table handler],
- [innodb="$withval"],
- [innodb=yes])
-
- AC_MSG_CHECKING([for Innodb])
-
- have_innodb=no
- innodb_includes=
- innodb_libs=
- case "$innodb" in
- yes )
- AC_MSG_RESULT([Using Innodb])
- AC_DEFINE([HAVE_INNOBASE_DB], [1], [Using Innobase DB])
- have_innodb="yes"
- innodb_includes="-I\$(top_builddir)/innobase/include -I\$(top_srcdir)/innobase/include"
- innodb_system_libs=""
-dnl Some libs are listed several times, in order for gcc to sort out
-dnl circular references.
- innodb_libs="\
- \$(top_builddir)/innobase/usr/libusr.a\
- \$(top_builddir)/innobase/srv/libsrv.a\
- \$(top_builddir)/innobase/dict/libdict.a\
- \$(top_builddir)/innobase/que/libque.a\
- \$(top_builddir)/innobase/srv/libsrv.a\
- \$(top_builddir)/innobase/ibuf/libibuf.a\
- \$(top_builddir)/innobase/row/librow.a\
- \$(top_builddir)/innobase/pars/libpars.a\
- \$(top_builddir)/innobase/btr/libbtr.a\
- \$(top_builddir)/innobase/trx/libtrx.a\
- \$(top_builddir)/innobase/read/libread.a\
- \$(top_builddir)/innobase/usr/libusr.a\
- \$(top_builddir)/innobase/buf/libbuf.a\
- \$(top_builddir)/innobase/ibuf/libibuf.a\
- \$(top_builddir)/innobase/eval/libeval.a\
- \$(top_builddir)/innobase/log/liblog.a\
- \$(top_builddir)/innobase/fsp/libfsp.a\
- \$(top_builddir)/innobase/fut/libfut.a\
- \$(top_builddir)/innobase/fil/libfil.a\
- \$(top_builddir)/innobase/lock/liblock.a\
- \$(top_builddir)/innobase/mtr/libmtr.a\
- \$(top_builddir)/innobase/page/libpage.a\
- \$(top_builddir)/innobase/rem/librem.a\
- \$(top_builddir)/innobase/thr/libthr.a\
- \$(top_builddir)/innobase/sync/libsync.a\
- \$(top_builddir)/innobase/data/libdata.a\
- \$(top_builddir)/innobase/mach/libmach.a\
- \$(top_builddir)/innobase/ha/libha.a\
- \$(top_builddir)/innobase/dyn/libdyn.a\
- \$(top_builddir)/innobase/mem/libmem.a\
- \$(top_builddir)/innobase/sync/libsync.a\
- \$(top_builddir)/innobase/ut/libut.a\
- \$(top_builddir)/innobase/os/libos.a\
- \$(top_builddir)/innobase/ut/libut.a"
-
- AC_CHECK_LIB(rt, aio_read, [innodb_system_libs="-lrt"])
- ;;
- * )
- AC_MSG_RESULT([Not using Innodb])
- ;;
- esac
-
- AC_SUBST(innodb_includes)
- AC_SUBST(innodb_libs)
- AC_SUBST(innodb_system_libs)
-])
-
-dnl ---------------------------------------------------------------------------
-dnl END OF MYSQL_CHECK_INNODB SECTION
-dnl ---------------------------------------------------------------------------
diff --git a/config/ac-macros/ha_ndbcluster.m4 b/config/ac-macros/ha_ndbcluster.m4
index 55fe6ad8350..9ea2e9972f7 100644
--- a/config/ac-macros/ha_ndbcluster.m4
+++ b/config/ac-macros/ha_ndbcluster.m4
@@ -1,8 +1,24 @@
dnl ---------------------------------------------------------------------------
dnl Macro: MYSQL_CHECK_NDBCLUSTER
-dnl Sets HAVE_NDBCLUSTER_DB if --with-ndbcluster is used
dnl ---------------------------------------------------------------------------
-
+
+NDB_VERSION_MAJOR=`echo $MYSQL_NO_DASH_VERSION | cut -d. -f1`
+NDB_VERSION_MINOR=`echo $MYSQL_NO_DASH_VERSION | cut -d. -f2`
+NDB_VERSION_BUILD=`echo $MYSQL_NO_DASH_VERSION | cut -d. -f3`
+NDB_VERSION_STATUS=`echo $VERSION | sed 's/^[[-.0-9]]*//'`
+TEST_NDBCLUSTER=""
+
+dnl for build ndb docs
+
+AC_PATH_PROG(DOXYGEN, doxygen, no)
+AC_PATH_PROG(PDFLATEX, pdflatex, no)
+AC_PATH_PROG(MAKEINDEX, makeindex, no)
+
+AC_SUBST(DOXYGEN)
+AC_SUBST(PDFLATEX)
+AC_SUBST(MAKEINDEX)
+
+
AC_DEFUN([MYSQL_CHECK_NDB_OPTIONS], [
AC_ARG_WITH([ndb-sci],
AC_HELP_STRING([--with-ndb-sci=DIR],
@@ -66,8 +82,13 @@ AC_DEFUN([MYSQL_CHECK_NDB_OPTIONS], [
[Extra CFLAGS for ndb compile]),
[ndb_ccflags=${withval}],
[ndb_ccflags=""])
+ AC_ARG_WITH([ndb-binlog],
+ [
+ --without-ndb-binlog Disable ndb binlog],
+ [ndb_binlog="$withval"],
+ [ndb_binlog="default"])
- case "$ndb_ccflags" in
+ case "$ndb_ccflags" in
"yes")
AC_MSG_RESULT([The --ndb-ccflags option requires a parameter (passed to CC for ndb compilation)])
;;
@@ -122,51 +143,231 @@ AC_DEFUN([MYSQL_CHECK_NDB_OPTIONS], [
AC_MSG_RESULT([done.])
])
-AC_DEFUN([MYSQL_CHECK_NDBCLUSTER], [
- AC_ARG_WITH([ndbcluster],
- [
- --with-ndbcluster Include the NDB Cluster table handler],
- [ndbcluster="$withval"],
- [ndbcluster=no])
-
- AC_MSG_CHECKING([for NDB Cluster])
-
- have_ndbcluster=no
- ndbcluster_includes=
- ndbcluster_libs=
- ndb_mgmclient_libs=
- case "$ndbcluster" in
- yes )
- AC_MSG_RESULT([Using NDB Cluster])
- AC_DEFINE([HAVE_NDBCLUSTER_DB], [1], [Using Ndb Cluster DB])
- have_ndbcluster="yes"
- ndbcluster_includes="-I\$(top_builddir)/ndb/include -I\$(top_srcdir)/ndb/include -I\$(top_srcdir)/ndb/include/ndbapi -I\$(top_srcdir)/ndb/include/mgmapi"
- ndbcluster_libs="\$(top_builddir)/ndb/src/.libs/libndbclient.a"
- ndbcluster_system_libs=""
- ndb_mgmclient_libs="\$(top_builddir)/ndb/src/mgmclient/libndbmgmclient.la"
- MYSQL_CHECK_NDB_OPTIONS
-
- # libndbclient versioning when linked with GNU ld.
- if $LD --version 2>/dev/null|grep -q GNU; then
- NDB_LD_VERSION_SCRIPT="-Wl,--version-script=\$(top_builddir)/ndb/src/libndb.ver"
- AC_CONFIG_FILES(ndb/src/libndb.ver)
- fi
- AC_SUBST(NDB_LD_VERSION_SCRIPT)
+AC_DEFUN([NDBCLUSTER_WORKAROUNDS], [
+ #workaround for Sun Forte/x86 see BUG#4681
+ case $SYSTEM_TYPE-$MACHINE_TYPE-$ac_cv_prog_gcc in
+ *solaris*-i?86-no)
+ CFLAGS="$CFLAGS -DBIG_TABLES"
+ CXXFLAGS="$CXXFLAGS -DBIG_TABLES"
;;
- * )
- AC_MSG_RESULT([Not using NDB Cluster])
+ *)
+ ;;
+ esac
+
+ # workaround for Sun Forte compile problem for ndb
+ case $SYSTEM_TYPE-$ac_cv_prog_gcc in
+ *solaris*-no)
+ ndb_cxxflags_fix="$ndb_cxxflags_fix -instances=static"
+ ;;
+ *)
+ ;;
+ esac
+
+ # ndb fail for whatever strange reason to link Sun Forte/x86
+ # unless using incremental linker
+ case $SYSTEM_TYPE-$MACHINE_TYPE-$ac_cv_prog_gcc-$have_ndbcluster in
+ *solaris*-i?86-no-yes)
+ CXXFLAGS="$CXXFLAGS -xildon"
+ ;;
+ *)
;;
esac
+])
+
+AC_DEFUN([MYSQL_SETUP_NDBCLUSTER], [
+
+ AC_MSG_RESULT([Using NDB Cluster])
+ with_partition="yes"
+ ndb_cxxflags_fix=""
+ TEST_NDBCLUSTER="--ndbcluster"
+
+ ndbcluster_includes="-I\$(top_builddir)/storage/ndb/include -I\$(top_srcdir)/storage/ndb/include -I\$(top_srcdir)/storage/ndb/include/ndbapi -I\$(top_srcdir)/storage/ndb/include/mgmapi"
+ ndbcluster_libs="\$(top_builddir)/storage/ndb/src/.libs/libndbclient.a"
+ ndbcluster_system_libs=""
+ ndb_mgmclient_libs="\$(top_builddir)/storage/ndb/src/mgmclient/libndbmgmclient.la"
+
+ MYSQL_CHECK_NDB_OPTIONS
+ NDBCLUSTER_WORKAROUNDS
+
+ MAKE_BINARY_DISTRIBUTION_OPTIONS="$MAKE_BINARY_DISTRIBUTION_OPTIONS --with-ndbcluster"
+
+ if test "$have_ndb_debug" = "default"
+ then
+ have_ndb_debug=$with_debug
+ fi
+
+ if test "$have_ndb_debug" = "yes"
+ then
+ # Medium debug.
+ NDB_DEFS="-DNDB_DEBUG -DVM_TRACE -DERROR_INSERT -DARRAY_GUARD"
+ elif test "$have_ndb_debug" = "full"
+ then
+ NDB_DEFS="-DNDB_DEBUG_FULL -DVM_TRACE -DERROR_INSERT -DARRAY_GUARD"
+ else
+ # no extra ndb debug but still do asserts if debug version
+ if test "$with_debug" = "yes" -o "$with_debug" = "full"
+ then
+ NDB_DEFS=""
+ else
+ NDB_DEFS="-DNDEBUG"
+ fi
+ fi
+
+ if test X"$ndb_port" = Xdefault
+ then
+ ndb_port="1186"
+ fi
+
+ have_ndb_binlog="no"
+ if test X"$ndb_binlog" = Xdefault ||
+ test X"$ndb_binlog" = Xyes
+ then
+ have_ndb_binlog="yes"
+ fi
+
+ if test X"$have_ndb_binlog" = Xyes
+ then
+ AC_DEFINE([WITH_NDB_BINLOG], [1],
+ [Including Ndb Cluster Binlog])
+ AC_MSG_RESULT([Including Ndb Cluster Binlog])
+ else
+ AC_MSG_RESULT([Not including Ndb Cluster Binlog])
+ fi
+
+ ndb_transporter_opt_objs=""
+ if test "$ac_cv_func_shmget" = "yes" &&
+ test "$ac_cv_func_shmat" = "yes" &&
+ test "$ac_cv_func_shmdt" = "yes" &&
+ test "$ac_cv_func_shmctl" = "yes" &&
+ test "$ac_cv_func_sigaction" = "yes" &&
+ test "$ac_cv_func_sigemptyset" = "yes" &&
+ test "$ac_cv_func_sigaddset" = "yes" &&
+ test "$ac_cv_func_pthread_sigmask" = "yes"
+ then
+ AC_DEFINE([NDB_SHM_TRANSPORTER], [1],
+ [Including Ndb Cluster DB shared memory transporter])
+ AC_MSG_RESULT([Including ndb shared memory transporter])
+ ndb_transporter_opt_objs="$ndb_transporter_opt_objs SHM_Transporter.lo SHM_Transporter.unix.lo"
+ else
+ AC_MSG_RESULT([Not including ndb shared memory transporter])
+ fi
+
+ if test X"$have_ndb_sci" = Xyes
+ then
+ ndb_transporter_opt_objs="$ndb_transporter_opt_objs SCI_Transporter.lo"
+ fi
+
+ ndb_opt_subdirs=
+ ndb_bin_am_ldflags="-static"
+ if test X"$have_ndb_test" = Xyes
+ then
+ ndb_opt_subdirs="test"
+ ndb_bin_am_ldflags=""
+ fi
+
+ if test X"$have_ndb_docs" = Xyes
+ then
+ ndb_opt_subdirs="$ndb_opt_subdirs docs"
+ ndb_bin_am_ldflags=""
+ fi
+
+ # building dynamic breaks on AIX. (If you want to try it and get unresolved
+ # __vec__delete2 and some such, try linking against libhC.)
+ case "$host_os" in
+ aix3.* | aix4.0.* | aix4.1.*) ;;
+ *) ndb_bin_am_ldflags="-static";;
+ esac
+
+ # libndbclient versioning when linked with GNU ld.
+ if $LD --version 2>/dev/null|grep -q GNU; then
+ NDB_LD_VERSION_SCRIPT="-Wl,--version-script=\$(top_builddir)/storage/ndb/src/libndb.ver"
+ AC_CONFIG_FILES(storage/ndb/src/libndb.ver)
+ fi
+ AC_SUBST(NDB_LD_VERSION_SCRIPT)
+
+ AC_SUBST(NDB_SHARED_LIB_MAJOR_VERSION)
+ AC_SUBST(NDB_SHARED_LIB_VERSION)
+
+
+ AC_SUBST(NDB_VERSION_MAJOR)
+ AC_SUBST(NDB_VERSION_MINOR)
+ AC_SUBST(NDB_VERSION_BUILD)
+ AC_SUBST(NDB_VERSION_STATUS)
+ AC_DEFINE_UNQUOTED([NDB_VERSION_MAJOR], [$NDB_VERSION_MAJOR],
+ [NDB major version])
+ AC_DEFINE_UNQUOTED([NDB_VERSION_MINOR], [$NDB_VERSION_MINOR],
+ [NDB minor version])
+ AC_DEFINE_UNQUOTED([NDB_VERSION_BUILD], [$NDB_VERSION_BUILD],
+ [NDB build version])
+ AC_DEFINE_UNQUOTED([NDB_VERSION_STATUS], ["$NDB_VERSION_STATUS"],
+ [NDB status version])
- AM_CONDITIONAL([HAVE_NDBCLUSTER_DB], [ test "$have_ndbcluster" = "yes" ])
AC_SUBST(ndbcluster_includes)
AC_SUBST(ndbcluster_libs)
AC_SUBST(ndbcluster_system_libs)
AC_SUBST(ndb_mgmclient_libs)
+ AC_SUBST(NDB_SCI_LIBS)
+
+ AC_SUBST(ndb_transporter_opt_objs)
+ AC_SUBST(ndb_port)
+ AC_SUBST(ndb_bin_am_ldflags)
+ AC_SUBST(ndb_opt_subdirs)
+
+ AC_SUBST(NDB_DEFS)
+ AC_SUBST(ndb_cxxflags_fix)
+ NDB_SIZEOF_CHARP="$ac_cv_sizeof_charp"
+ NDB_SIZEOF_CHAR="$ac_cv_sizeof_char"
+ NDB_SIZEOF_SHORT="$ac_cv_sizeof_short"
+ NDB_SIZEOF_INT="$ac_cv_sizeof_int"
+ NDB_SIZEOF_LONG="$ac_cv_sizeof_long"
+ NDB_SIZEOF_LONG_LONG="$ac_cv_sizeof_long_long"
+ AC_SUBST([NDB_SIZEOF_CHARP])
+ AC_SUBST([NDB_SIZEOF_CHAR])
+ AC_SUBST([NDB_SIZEOF_SHORT])
+ AC_SUBST([NDB_SIZEOF_INT])
+ AC_SUBST([NDB_SIZEOF_LONG])
+ AC_SUBST([NDB_SIZEOF_LONG_LONG])
+
+ AC_CONFIG_FILES(storage/ndb/include/Makefile dnl
+ storage/ndb/src/Makefile storage/ndb/src/common/Makefile dnl
+ storage/ndb/docs/Makefile dnl
+ storage/ndb/tools/Makefile dnl
+ storage/ndb/src/common/debugger/Makefile dnl
+ storage/ndb/src/common/debugger/signaldata/Makefile dnl
+ storage/ndb/src/common/portlib/Makefile dnl
+ storage/ndb/src/common/util/Makefile dnl
+ storage/ndb/src/common/logger/Makefile dnl
+ storage/ndb/src/common/transporter/Makefile dnl
+ storage/ndb/src/common/mgmcommon/Makefile dnl
+ storage/ndb/src/kernel/Makefile dnl
+ storage/ndb/src/kernel/error/Makefile dnl
+ storage/ndb/src/kernel/blocks/Makefile dnl
+ storage/ndb/src/kernel/blocks/dbdict/Makefile dnl
+ storage/ndb/src/kernel/blocks/dbdih/Makefile dnl
+ storage/ndb/src/kernel/blocks/dblqh/Makefile dnl
+ storage/ndb/src/kernel/blocks/dbtup/Makefile dnl
+ storage/ndb/src/kernel/blocks/backup/Makefile dnl
+ storage/ndb/src/kernel/vm/Makefile dnl
+ storage/ndb/src/mgmapi/Makefile dnl
+ storage/ndb/src/ndbapi/Makefile dnl
+ storage/ndb/src/mgmsrv/Makefile dnl
+ storage/ndb/src/mgmclient/Makefile dnl
+ storage/ndb/src/cw/Makefile dnl
+ storage/ndb/src/cw/cpcd/Makefile dnl
+ storage/ndb/test/Makefile dnl
+ storage/ndb/test/src/Makefile dnl
+ storage/ndb/test/ndbapi/Makefile dnl
+ storage/ndb/test/ndbapi/bank/Makefile dnl
+ storage/ndb/test/tools/Makefile dnl
+ storage/ndb/test/run-test/Makefile dnl
+ storage/ndb/include/ndb_version.h storage/ndb/include/ndb_global.h dnl
+ storage/ndb/include/ndb_types.h dnl
+ )
])
-
+
+AC_SUBST(TEST_NDBCLUSTER)
dnl ---------------------------------------------------------------------------
dnl END OF MYSQL_CHECK_NDBCLUSTER SECTION
dnl ---------------------------------------------------------------------------
diff --git a/config/ac-macros/ha_tina.m4 b/config/ac-macros/ha_tina.m4
deleted file mode 100644
index fe6e382ce20..00000000000
--- a/config/ac-macros/ha_tina.m4
+++ /dev/null
@@ -1,29 +0,0 @@
-dnl ---------------------------------------------------------------------------
-dnl Macro: MYSQL_CHECK_CSVDB
-dnl Sets HAVE_CSV_DB if --with-csv-storage-engine is used
-dnl ---------------------------------------------------------------------------
-AC_DEFUN([MYSQL_CHECK_CSVDB], [
- AC_ARG_WITH([csv-storage-engine],
- [
- --with-csv-storage-engine
- Enable the CSV Storage Engine],
- [csvdb="$withval"],
- [csvdb=no])
- AC_MSG_CHECKING([for csv storage engine])
-
- case "$csvdb" in
- yes )
- AC_DEFINE([HAVE_CSV_DB], [1], [Builds the CSV Storage Engine])
- AC_MSG_RESULT([yes])
- [csvdb=yes]
- ;;
- * )
- AC_MSG_RESULT([no])
- [csvdb=no]
- ;;
- esac
-
-])
-dnl ---------------------------------------------------------------------------
-dnl END OF MYSQL_CHECK_CSV SECTION
-dnl ---------------------------------------------------------------------------
diff --git a/config/ac-macros/misc.m4 b/config/ac-macros/misc.m4
index 8c3b51ebc5e..2fbb30383bd 100644
--- a/config/ac-macros/misc.m4
+++ b/config/ac-macros/misc.m4
@@ -1,35 +1,5 @@
# Local macros for automake & autoconf
-# A local version of AC_CHECK_SIZEOF that includes sys/types.h
-dnl MYSQL_CHECK_SIZEOF(TYPE [, CROSS-SIZE])
-AC_DEFUN([MYSQL_CHECK_SIZEOF],
-[changequote(<<, >>)dnl
-dnl The name to #define.
-define(<<AC_TYPE_NAME>>, translit(sizeof_$1, [a-z *], [A-Z_P]))dnl
-dnl The cache variable name.
-define(<<AC_CV_NAME>>, translit(ac_cv_sizeof_$1, [ *], [_p]))dnl
-changequote([, ])dnl
-AC_MSG_CHECKING(size of $1)
-AC_CACHE_VAL(AC_CV_NAME,
-[AC_TRY_RUN([#include <stdio.h>
-#include <sys/types.h>
-#if STDC_HEADERS
-#include <stdlib.h>
-#include <stddef.h>
-#endif
-main()
-{
- FILE *f=fopen("conftestval", "w");
- if (!f) exit(1);
- fprintf(f, "%d\n", sizeof($1));
- exit(0);
-}], AC_CV_NAME=`cat conftestval`, AC_CV_NAME=0, ifelse([$2], , , AC_CV_NAME=$2))])dnl
-AC_MSG_RESULT($AC_CV_NAME)
-AC_DEFINE_UNQUOTED(AC_TYPE_NAME, $AC_CV_NAME, [ ])
-undefine([AC_TYPE_NAME])dnl
-undefine([AC_CV_NAME])dnl
-])
-
#---START: Used in for client configure
AC_DEFUN([MYSQL_TYPE_ACCEPT],
[ac_save_CXXFLAGS="$CXXFLAGS"
@@ -155,84 +125,6 @@ fi
])
-#---START: Used in for client configure
-AC_DEFUN([MYSQL_CHECK_ULONG],
-[AC_MSG_CHECKING(for type ulong)
-AC_CACHE_VAL(ac_cv_ulong,
-[AC_TRY_RUN([#include <stdio.h>
-#include <sys/types.h>
-main()
-{
- ulong foo;
- foo++;
- exit(0);
-}], ac_cv_ulong=yes, ac_cv_ulong=no, ac_cv_ulong=no)])
-AC_MSG_RESULT($ac_cv_ulong)
-if test "$ac_cv_ulong" = "yes"
-then
- AC_DEFINE([HAVE_ULONG], [1], [system headers define ulong])
-fi
-])
-
-AC_DEFUN([MYSQL_CHECK_UCHAR],
-[AC_MSG_CHECKING(for type uchar)
-AC_CACHE_VAL(ac_cv_uchar,
-[AC_TRY_RUN([#include <stdio.h>
-#include <sys/types.h>
-main()
-{
- uchar foo;
- foo++;
- exit(0);
-}], ac_cv_uchar=yes, ac_cv_uchar=no, ac_cv_uchar=no)])
-AC_MSG_RESULT($ac_cv_uchar)
-if test "$ac_cv_uchar" = "yes"
-then
- AC_DEFINE([HAVE_UCHAR], [1], [system headers define uchar])
-fi
-])
-
-AC_DEFUN([MYSQL_CHECK_UINT],
-[AC_MSG_CHECKING(for type uint)
-AC_CACHE_VAL(ac_cv_uint,
-[AC_TRY_RUN([#include <stdio.h>
-#include <sys/types.h>
-main()
-{
- uint foo;
- foo++;
- exit(0);
-}], ac_cv_uint=yes, ac_cv_uint=no, ac_cv_uint=no)])
-AC_MSG_RESULT($ac_cv_uint)
-if test "$ac_cv_uint" = "yes"
-then
- AC_DEFINE([HAVE_UINT], [1], [system headers define uint])
-fi
-])
-
-
-AC_DEFUN([MYSQL_CHECK_IN_ADDR_T],
-[AC_MSG_CHECKING(for type in_addr_t)
-AC_CACHE_VAL(ac_cv_in_addr_t,
-[AC_TRY_RUN([#include <stdio.h>
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-
-int main(int argc, char **argv)
-{
- in_addr_t foo;
- exit(0);
-}], ac_cv_in_addr_t=yes, ac_cv_in_addr_t=no, ac_cv_in_addr_t=no)])
-AC_MSG_RESULT($ac_cv_in_addr_t)
-if test "$ac_cv_in_addr_t" = "yes"
-then
- AC_DEFINE([HAVE_IN_ADDR_T], [1], [system headers define in_addr_t])
-fi
-])
-
-
AC_DEFUN([MYSQL_PTHREAD_YIELD],
[AC_CACHE_CHECK([if pthread_yield takes zero arguments], ac_cv_pthread_yield_zero_arg,
[AC_TRY_LINK([#define _GNU_SOURCE
@@ -272,25 +164,6 @@ fi
#---END:
-AC_DEFUN([MYSQL_CHECK_FP_EXCEPT],
-[AC_MSG_CHECKING(for type fp_except)
-AC_CACHE_VAL(ac_cv_fp_except,
-[AC_TRY_RUN([#include <stdio.h>
-#include <sys/types.h>
-#include <ieeefp.h>
-main()
-{
- fp_except foo;
- foo++;
- exit(0);
-}], ac_cv_fp_except=yes, ac_cv_fp_except=no, ac_cv_fp_except=no)])
-AC_MSG_RESULT($ac_cv_fp_except)
-if test "$ac_cv_fp_except" = "yes"
-then
- AC_DEFINE([HAVE_FP_EXCEPT], [1], [fp_except from ieeefp.h])
-fi
-])
-
# From fileutils-3.14/aclocal.m4
# @defmac AC_PROG_CC_STDC
@@ -596,7 +469,7 @@ AC_DEFUN([MYSQL_STACK_DIRECTION],
{
exit (find_stack_direction() < 0);
}], ac_cv_c_stack_direction=1, ac_cv_c_stack_direction=-1,
- ac_cv_c_stack_direction=0)])
+ ac_cv_c_stack_direction=)])
AC_DEFINE_UNQUOTED(STACK_DIRECTION, $ac_cv_c_stack_direction)
])dnl
@@ -606,7 +479,7 @@ AC_MSG_CHECKING(if conversion of longlong to float works)
AC_CACHE_VAL(ac_cv_conv_longlong_to_float,
[AC_TRY_RUN([#include <stdio.h>
typedef long long longlong;
-main()
+int main()
{
longlong ll=1;
float f;
@@ -614,8 +487,10 @@ main()
f = (float) ll;
fprintf(file,"%g\n",f);
fclose(file);
- exit (0);
-}], ac_cv_conv_longlong_to_float=`cat conftestval`, ac_cv_conv_longlong_to_float=0, ifelse([$2], , , ac_cv_conv_longlong_to_float=$2))])dnl
+ return (0);
+}], ac_cv_conv_longlong_to_float=`cat conftestval`,
+ ac_cv_conv_longlong_to_float=0,
+ ac_cv_conv_longlong_to_float="yes")])dnl # Cross compiling, assume can convert
if test "$ac_cv_conv_longlong_to_float" = "1" -o "$ac_cv_conv_longlong_to_float" = "yes"
then
ac_cv_conv_longlong_to_float=yes
@@ -675,8 +550,8 @@ dnl Sets BIG_TABLES if --with-big-tables is used
dnl ---------------------------------------------------------------------------
AC_DEFUN([MYSQL_CHECK_BIG_TABLES], [
AC_ARG_WITH([big-tables],
- [
- --with-big-tables Support tables with more than 4 G rows even on 32 bit platforms],
+ AS_HELP_STRING([--with-big-tables],
+ [Support tables with more than 4 G rows even on 32 bit platforms]),
[bigtables="$withval"],
[bigtables=no])
AC_MSG_CHECKING([for big tables support])
@@ -703,8 +578,8 @@ dnl Sets MAX_INDEXES
dnl ---------------------------------------------------------------------------
AC_DEFUN([MYSQL_CHECK_MAX_INDEXES], [
AC_ARG_WITH([max-indexes],
- [
- --with-max-indexes=\# Sets the maximum number of indexes per table, default 64],
+ AS_HELP_STRING([--with-max-indexes=N],
+ [Sets the maximum number of indexes per table, default 64]),
[max_indexes="$withval"],
[max_indexes=64])
AC_MSG_CHECKING([max indexes per table])
diff --git a/config/ac-macros/openssl.m4 b/config/ac-macros/openssl.m4
deleted file mode 100644
index 9de69b8a1b4..00000000000
--- a/config/ac-macros/openssl.m4
+++ /dev/null
@@ -1,138 +0,0 @@
-AC_DEFUN([MYSQL_FIND_OPENSSL], [
- incs="$1"
- libs="$2"
- eval shrexts=\"$shrext_cmds\"
- case "$incs---$libs" in
- ---)
- for d in /usr/ssl/include /usr/local/ssl/include /usr/include \
-/usr/include/ssl /opt/ssl/include /opt/openssl/include \
-/usr/local/ssl/include /usr/local/include /usr/freeware/include ; do
- if test -f $d/openssl/ssl.h ; then
- OPENSSL_INCLUDE=-I$d
- fi
- done
-
- for d in /usr/ssl/lib /usr/local/ssl/lib /usr/lib/openssl \
-/usr/lib /usr/lib64 /opt/ssl/lib /opt/openssl/lib \
-/usr/freeware/lib32 /usr/local/lib/ ; do
- # Test for libssl using all known library file endings
- if test -f $d/libssl.a || test -f $d/libssl.so || \
- test -f $d/libssl.sl || test -f $d/libssl.dylib ; then
- OPENSSL_LIB=$d
- fi
- done
- ;;
- ---* | *---)
- AC_MSG_ERROR([if either 'includes' or 'libs' is specified, both must be specified])
- ;;
- * )
- if test -f $incs/openssl/ssl.h ; then
- OPENSSL_INCLUDE=-I$incs
- fi
- # Test for libssl using all known library file endings
- if test -f $libs/libssl.a || test -f $libs/libssl.so || \
- test -f $libs/libssl.sl || test -f $libs/libssl.dylib ; then
- OPENSSL_LIB=$libs
- fi
- ;;
- esac
-
- # On RedHat 9 we need kerberos to compile openssl
- for d in /usr/kerberos/include
- do
- if test -f $d/krb5.h ; then
- OPENSSL_KERBEROS_INCLUDE="$d"
- fi
- done
-
-
- if test -z "$OPENSSL_LIB" -o -z "$OPENSSL_INCLUDE" ; then
- echo "Could not find an installation of OpenSSL"
- if test -n "$OPENSSL_LIB" ; then
- if test "$TARGET_LINUX" = "true"; then
- echo "Looks like you've forgotten to install OpenSSL development RPM"
- fi
- fi
- exit 1
- fi
-
-])
-
-AC_DEFUN([MYSQL_CHECK_OPENSSL], [
-AC_MSG_CHECKING(for OpenSSL)
- AC_ARG_WITH([openssl],
- [ --with-openssl[=DIR] Include the OpenSSL support],
- [openssl="$withval"],
- [openssl=no])
-
- AC_ARG_WITH([openssl-includes],
- [
- --with-openssl-includes=DIR
- Find OpenSSL headers in DIR],
- [openssl_includes="$withval"],
- [openssl_includes=""])
-
- AC_ARG_WITH([openssl-libs],
- [
- --with-openssl-libs=DIR
- Find OpenSSL libraries in DIR],
- [openssl_libs="$withval"],
- [openssl_libs=""])
-
- if test "$openssl" != "no"
- then
- if test "$openssl" != "yes"
- then
- if test -z "$openssl_includes"
- then
- openssl_includes="$openssl/include"
- fi
- if test -z "$openssl_libs"
- then
- openssl_libs="$openssl/lib"
- fi
- fi
- MYSQL_FIND_OPENSSL([$openssl_includes], [$openssl_libs])
- #force VIO use
- AC_MSG_RESULT(yes)
- openssl_libs="-L$OPENSSL_LIB -lssl -lcrypto"
- # Don't set openssl_includes to /usr/include as this gives us a lot of
- # compiler warnings when using gcc 3.x
- openssl_includes=""
- if test "$OPENSSL_INCLUDE" != "-I/usr/include"
- then
- openssl_includes="$OPENSSL_INCLUDE"
- fi
- if test "$OPENSSL_KERBEROS_INCLUDE"
- then
- openssl_includes="$openssl_includes -I$OPENSSL_KERBEROS_INCLUDE"
- fi
- AC_DEFINE([HAVE_OPENSSL], [1], [OpenSSL])
-
- # openssl-devel-0.9.6 requires dlopen() and we can't link staticly
- # on many platforms (We should actually test this here, but it's quite
- # hard) to do as we are doing libtool for linking.
- using_static=""
- case "$CLIENT_EXTRA_LDFLAGS $MYSQLD_EXTRA_LDFLAGS" in
- *-all-static*) using_static="yes" ;;
- esac
- if test "$using_static" = "yes"
- then
- echo "You can't use the --all-static link option when using openssl."
- exit 1
- fi
- NON_THREADED_CLIENT_LIBS="$NON_THREADED_CLIENT_LIBS $openssl_libs"
- else
- AC_MSG_RESULT(no)
- if test ! -z "$openssl_includes"
- then
- AC_MSG_ERROR(Can't have --with-openssl-includes without --with-openssl)
- fi
- if test ! -z "$openssl_libs"
- then
- AC_MSG_ERROR(Can't have --with-openssl-libs without --with-openssl)
- fi
- fi
- AC_SUBST(openssl_libs)
- AC_SUBST(openssl_includes)
-])
diff --git a/config/ac-macros/plugins.m4 b/config/ac-macros/plugins.m4
new file mode 100644
index 00000000000..8dfb698709f
--- /dev/null
+++ b/config/ac-macros/plugins.m4
@@ -0,0 +1,815 @@
+dnl ===========================================================================
+dnl Support for mysql server plugins
+dnl ===========================================================================
+dnl
+dnl WorkLog#3201
+dnl
+dnl Framework for pluggable static and dynamic plugins for mysql
+dnl
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN([name],[Plugin name],
+dnl [Plugin description],
+dnl [group,group...])
+dnl
+dnl DESCRIPTION
+dnl First declaration for a plugin (mandatory).
+dnl Adds plugin as member to configuration groups (if specified)
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN],[
+ _MYSQL_PLUGIN(
+ [$1],
+ [__MYSQL_PLUGIN_]AS_TR_CPP([$1])[__],
+ m4_default([$2], [$1 plugin]),
+ m4_default([$3], [plugin for $1]),
+ m4_default([$4], []),
+ )
+])
+
+AC_DEFUN([_MYSQL_PLUGIN],[
+ m4_ifdef([$2], [
+ AC_FATAL([Duplicate MYSQL_PLUGIN declaration for $3])
+ ],[
+ m4_define([$2], [$1])
+ _MYSQL_PLUGAPPEND([__mysql_plugin_list__],[$1])
+ m4_define([MYSQL_PLUGIN_NAME_]AS_TR_CPP([$1]), [$3])
+ m4_define([MYSQL_PLUGIN_DESC_]AS_TR_CPP([$1]), [$4])
+ _MYSQL_PLUGAPPEND_META([$1], $5)
+ ifelse(m4_bregexp(__mysql_include__,[/plug\.in$]),-1,[],[
+ MYSQL_PLUGIN_DIRECTORY([$1],
+ m4_bregexp(__mysql_include__,[^\(.*\)/plug\.in$],[\1]))
+ ])
+ ])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_STORAGE_ENGINE
+dnl
+dnl SYNOPSIS
+dnl MYSQL_STORAGE_ENGINE([name],[legacy-option],[Storage engine name],
+dnl [Storage engine description],[group,group...])
+dnl
+dnl DESCRIPTION
+dnl Short cut for storage engine declarations
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_STORAGE_ENGINE],[
+ MYSQL_PLUGIN([$1], [$3], [$4], [[$5]])
+ MYSQL_PLUGIN_DEFINE([$1], [WITH_]AS_TR_CPP([$1])[_STORAGE_ENGINE])
+ ifelse([$2],[no],[],[
+ _MYSQL_LEGACY_STORAGE_ENGINE(
+ m4_bpatsubst([$1], -, _),
+ m4_bpatsubst(m4_default([$2], [$1-storage-engine]), -, _))
+ ])
+])
+
+AC_DEFUN([_MYSQL_LEGACY_STORAGE_ENGINE],[
+if test "[${with_]$2[+set}]" = set; then
+ [with_plugin_]$1="[$with_]$2"
+fi
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_DEFINE
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_DEFINE([name],[MYSQL_CPP_DEFINE])
+dnl
+dnl DESCRIPTION
+dnl When a plugin is to be statically linked, define the C macro
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_DEFINE],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ m4_define([MYSQL_PLUGIN_DEFINE_]AS_TR_CPP([$1]), [$2])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_DIRECTORY
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_DIRECTORY([name],[plugin/dir])
+dnl
+dnl DESCRIPTION
+dnl Adds a directory to the build process
+dnl if it contains 'configure' it will be picked up automatically
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_DIRECTORY],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ m4_define([MYSQL_PLUGIN_DIRECTORY_]AS_TR_CPP([$1]), [$2])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_STATIC
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_STATIC([name],[libmyplugin.a])
+dnl
+dnl DESCRIPTION
+dnl Declare the name for the static library
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_STATIC],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ m4_define([MYSQL_PLUGIN_STATIC_]AS_TR_CPP([$1]), [$2])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_DYNAMIC
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_DYNAMIC([name],[myplugin.la])
+dnl
+dnl DESCRIPTION
+dnl Declare the name for the shared library
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_DYNAMIC],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ m4_define([MYSQL_PLUGIN_DYNAMIC_]AS_TR_CPP([$1]), [$2])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_MANDATORY
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_MANDATORY([name])
+dnl
+dnl DESCRIPTION
+dnl Marks the specified plugin as a mandatory plugin
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_MANDATORY],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ _MYSQL_PLUGIN_MANDATORY([$1],
+ [MYSQL_PLUGIN_MANDATORY_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DISABLED_]AS_TR_CPP([$1])
+ )
+])
+
+AC_DEFUN([_MYSQL_PLUGIN_MANDATORY],[
+ m4_define([$2], [yes])
+ m4_ifdef([$3], [
+ AC_FATAL([mandatory plugin $1 has been disabled])
+ m4_undefine([$2])
+ ])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_DISABLED
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_DISABLED([name])
+dnl
+dnl DESCRIPTION
+dnl Marks the specified plugin as a disabled plugin
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_DISABLED],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ _MYSQL_PLUGIN_DISABLED([$1],
+ [MYSQL_PLUGIN_DISABLED_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_MANDATORY_]AS_TR_CPP([$1])
+ )
+])
+
+AC_DEFUN([_MYSQL_PLUGIN_DISABLED],[
+ m4_define([$2], [yes])
+ m4_ifdef([$3], [
+ AC_FATAL([attempt to disable mandatory plugin $1])
+ m4_undefine([$2])
+ ])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_DEPENDS
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_DEPENDS([name],[prereq,prereq...])
+dnl
+dnl DESCRIPTION
+dnl Enables other plugins neccessary for the named plugin
+dnl Dependency checking is not recursive so if any
+dnl required plugin requires further plugins, list them
+dnl here too!
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_DEPENDS],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ ifelse($#, 2, [
+ _MYSQL_PLUGIN_DEPEND([$1], $2)
+ ], [
+ AC_FATAL([bad number of arguments])
+ ])
+])
+
+AC_DEFUN([_MYSQL_PLUGIN_DEPEND],[
+ ifelse($#, 1, [], [$#:$2], [2:], [], [
+ MYSQL_REQUIRE_PLUGIN([$2])
+ _MYSQL_PLUGAPPEND([__mysql_plugdepends_$1__],[$2])
+ _MYSQL_PLUGIN_DEPEND([$1], m4_shift(m4_shift($@)))
+ ])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_ACTIONS
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_ACTIONS([name],[PLUGIN_CONFIGURE_STUFF])
+dnl
+dnl DESCRIPTION
+dnl Declares additional autoconf actions required to configure the plugin
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_ACTIONS],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ m4_ifdef([$2],[
+ m4_define([MYSQL_PLUGIN_ACTIONS_]AS_TR_CPP([$1]),m4_defn([$2]))
+ ],[
+ m4_define([MYSQL_PLUGIN_ACTIONS_]AS_TR_CPP([$1]), [$2])
+ ])
+])
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS([name],[file name])
+dnl
+dnl DESCRIPTION
+dnl Some modules in plugins keep dependance on structures
+dnl declared in sql/ (THD class usually)
+dnl That has to be fixed in the future, but until then
+dnl we have to recompile these modules when we want to
+dnl to compile server parts with the different #defines
+dnl Normally it happens when we compile the embedded server
+dnl Thus one should mark such files in his handler using this macro
+dnl (currently only one such a file per plugin is supported)
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS],[
+ MYSQL_REQUIRE_PLUGIN([$1])
+ m4_define([MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS_]AS_TR_CPP([$1]), [$2])
+])
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_CONFIGURE_PLUGINS
+dnl
+dnl SYNOPSIS
+dnl MYSQL_PLUGIN_DEPENDS([name,name...])
+dnl
+dnl DESCRIPTION
+dnl Used last, emits all required shell code to configure the plugins
+dnl Argument is a list of default plugins or meta-plugin
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_CONFIGURE_PLUGINS],[
+ m4_ifdef([__mysql_plugin_configured__],[
+ AC_FATAL([cannot use [MYSQL_CONFIGURE_PLUGINS] multiple times])
+ ],[
+ m4_define([__mysql_plugin_configured__],[done])
+ _MYSQL_INCLUDE_LIST(
+ m4_bpatsubst(m4_esyscmd([ls plugin/*/plug.in storage/*/plug.in 2>/dev/null]),
+[[
+]],[,]))
+ m4_ifdef([__mysql_plugin_list__],[
+ _MYSQL_CHECK_PLUGIN_ARGS([$1])
+ _MYSQL_CONFIGURE_PLUGINS(m4_bpatsubst(__mysql_plugin_list__, :, [,]))
+ _MYSQL_EMIT_PLUGIN_ACTIONS(m4_bpatsubst(__mysql_plugin_list__, :, [,]))
+ AC_SUBST([mysql_se_dirs])
+ AC_SUBST([mysql_pg_dirs])
+ AC_SUBST([mysql_se_unittest_dirs])
+ AC_SUBST([mysql_pg_unittest_dirs])
+ AC_SUBST([condition_dependent_plugin_modules])
+ AC_SUBST([condition_dependent_plugin_objects])
+ AC_SUBST([condition_dependent_plugin_links])
+ AC_SUBST([condition_dependent_plugin_includes])
+ ])
+ ])
+])
+
+AC_DEFUN([_MYSQL_CONFIGURE_PLUGINS],[
+ ifelse($#, 0, [], $#, 1, [
+ _MYSQL_EMIT_CHECK_PLUGIN([$1])
+ ],[
+ _MYSQL_EMIT_CHECK_PLUGIN([$1])
+ _MYSQL_CONFIGURE_PLUGINS(m4_shift($@))
+ ])
+])
+
+AC_DEFUN([_MYSQL_EMIT_CHECK_PLUGIN],[
+ __MYSQL_EMIT_CHECK_PLUGIN(
+ [$1],
+ m4_bpatsubst([$1], -, _),
+ [MYSQL_PLUGIN_NAME_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DESC_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DEFINE_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DIRECTORY_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_STATIC_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DYNAMIC_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_MANDATORY_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DISABLED_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_ACTIONS_]AS_TR_CPP([$1])
+ )
+])
+
+AC_DEFUN([__MYSQL_EMIT_CHECK_PLUGIN],[
+ m4_ifdef([$5],[
+ AH_TEMPLATE($5, [Include ]$4[ into mysqld])
+ ])
+ AC_MSG_CHECKING([whether to use ]$3)
+ mysql_use_plugin_dir=""
+ m4_ifdef([$10],[
+ if test "X[$mysql_plugin_]$2" = Xyes -a \
+ "X[$with_plugin_]$2" != Xno -o \
+ "X[$with_plugin_]$2" = Xyes; then
+ AC_MSG_RESULT([error])
+ AC_MSG_ERROR([disabled])
+ fi
+ AC_MSG_RESULT([no])
+ ],[
+ m4_ifdef([$9],[
+ if test "X[$with_plugin_]$2" = Xno; then
+ AC_MSG_RESULT([error])
+ AC_MSG_ERROR([cannot disable mandatory plugin])
+ fi
+ [mysql_plugin_]$2=yes
+ ],[
+ case "$with_mysqld_ldflags " in
+ *"-all-static "*)
+ # No need to build shared plugins when mysqld is linked with
+ # -all-static as it won't be able to load them.
+ if test "X[$mysql_plugin_]$2" != Xyes -a \
+ "X[$with_plugin_]$2" != Xyes; then
+ [with_plugin_]$2=no
+ fi
+ ;;
+ esac
+ ])
+ if test "X[$with_plugin_]$2" = Xno; then
+ AC_MSG_RESULT([no])
+ else
+ m4_ifdef([$8],m4_ifdef([$7],[],[[with_plugin_]$2='']))
+ if test "X[$mysql_plugin_]$2" != Xyes -a \
+ "X[$with_plugin_]$2" != Xyes; then
+ m4_ifdef([$8],[
+ m4_ifdef([$6],[
+ if test -d "$srcdir/$6" ; then
+ mysql_use_plugin_dir="$6"
+ ])
+ AC_SUBST([plugin_]$2[_shared_target], "$8")
+ AC_SUBST([plugin_]$2[_static_target], [""])
+ [with_plugin_]$2=yes
+ AC_MSG_RESULT([plugin])
+ m4_ifdef([$6],[
+ else
+ [mysql_plugin_]$2=no
+ AC_MSG_RESULT([no])
+ fi
+ ])
+ ],[
+ [with_plugin_]$2=no
+ AC_MSG_RESULT([no])
+ ])
+ else
+ m4_ifdef([$7],[
+ ifelse(m4_bregexp($7, [^lib[^.]+\.a$]), -2, [
+dnl change above "-2" to "0" to enable this section
+dnl Although this is "pretty", it breaks libmysqld build
+ m4_ifdef([$6],[
+ mysql_use_plugin_dir="$6"
+ mysql_plugin_libs="$mysql_plugin_libs -L[\$(top_builddir)]/$6"
+ ])
+ mysql_plugin_libs="$mysql_plugin_libs dnl
+[-l]m4_bregexp($7, [^lib\([^.]+\)], [\1])"
+ ], m4_bregexp($7, [^\\\$]), 0, [
+ m4_ifdef([$6],[
+ mysql_use_plugin_dir="$6"
+ ])
+ mysql_plugin_libs="$mysql_plugin_libs $7"
+ ], [
+ m4_ifdef([$6],[
+ mysql_use_plugin_dir="$6"
+ mysql_plugin_libs="$mysql_plugin_libs \$(top_builddir)/$6/$7"
+ ],[
+ mysql_plugin_libs="$mysql_plugin_libs $7"
+ ])
+ ])
+ m4_ifdef([$5],[
+ AC_DEFINE($5)
+ ])
+ AC_SUBST([plugin_]$2[_static_target], "$7")
+ AC_SUBST([plugin_]$2[_shared_target], [""])
+ ],[
+ m4_ifdef([$6],[
+ AC_MSG_RESULT([error])
+ AC_MSG_ERROR([Plugin $1 does not support static linking])
+ ],[
+ m4_ifdef([$5],[
+ AC_DEFINE($5)
+ AC_SUBST([plugin_]$2[_static_target], ["yes"])
+ AC_SUBST([plugin_]$2[_shared_target], [""])
+ ])
+ ])
+ ])
+ mysql_plugin_defs="$mysql_plugin_defs, [builtin_]$2[_plugin]"
+ [with_plugin_]$2=yes
+ AC_MSG_RESULT([yes])
+ m4_ifdef([$11],[
+ condition_dependent_plugin_modules="$condition_dependent_plugin_modules m4_bregexp($11, [[^/]+$], [\&])"
+ condition_dependent_plugin_objects="$condition_dependent_plugin_objects m4_bregexp($11, [[^/]+\.], [\&o])"
+ condition_dependent_plugin_links="$condition_dependent_plugin_links $6/$11"
+ condition_dependent_plugin_includes="$condition_dependent_plugin_includes -I[\$(top_srcdir)]/$6/m4_bregexp($11, [^.+[/$]], [\&])"
+ ])
+ fi
+ m4_ifdef([$6],[
+ if test -n "$mysql_use_plugin_dir" ; then
+ mysql_plugin_dirs="$mysql_plugin_dirs $6"
+ m4_syscmd(test -f "$6/configure")
+ ifelse(m4_sysval, 0,
+ [AC_CONFIG_SUBDIRS($6)],
+ [AC_CONFIG_FILES($6/Makefile)]
+ )
+ ifelse(m4_substr($6, 0, 8), [storage/],
+ [
+ [mysql_se_dirs="$mysql_se_dirs ]m4_substr($6, 8)"
+ mysql_se_unittest_dirs="$mysql_se_unittest_dirs ../$6"
+ ],
+ m4_substr($6, 0, 7), [plugin/],
+ [
+ [mysql_pg_dirs="$mysql_pg_dirs ]m4_substr($6, 7)"
+ mysql_pg_unittest_dirs="$mysql_pg_unittest_dirs ../$6"
+ ],
+ [AC_FATAL([don't know how to handle plugin dir ]$6)])
+ fi
+ ])
+ fi
+ ])
+])
+
+AC_DEFUN([_MYSQL_EMIT_PLUGIN_ACTIONS],[
+ ifelse($#, 0, [], $#, 1, [
+ _MYSQL_EMIT_PLUGIN_ACTION([$1])
+ ],[
+ _MYSQL_EMIT_PLUGIN_ACTION([$1])
+ _MYSQL_EMIT_PLUGIN_ACTIONS(m4_shift($@))
+ ])
+])
+
+AC_DEFUN([_MYSQL_EMIT_PLUGIN_ACTION],[
+ __MYSQL_EMIT_PLUGIN_ACTION(
+ [$1],
+ m4_bpatsubst([$1], -, _),
+ [MYSQL_PLUGIN_DISABLED_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_ACTIONS_]AS_TR_CPP([$1])
+ )
+])
+
+
+AC_DEFUN([__MYSQL_EMIT_PLUGIN_ACTION],[
+ m4_ifdef([$3], [], [
+ if test "X[$with_plugin_]$2" = Xyes; then
+ if test "X[$plugin_]$2[_static_target]" = X -a \
+ "X[$plugin_]$2[_shared_target]" = X; then
+ AC_MSG_ERROR([that's strange, $1 failed sanity check])
+ fi
+ $4
+ fi
+ ])
+])
+
+
+
+dnl ===========================================================================
+dnl Private helper macros
+dnl ===========================================================================
+
+
+dnl SYNOPSIS
+dnl MYSQL_REQUIRE_PLUGIN([name])
+dnl
+dnl DESCRIPTION
+dnl Checks that the specified plugin does exist
+
+AC_DEFUN([MYSQL_REQUIRE_PLUGIN],[
+ _MYSQL_REQUIRE_PLUGIN([$1], [__MYSQL_PLUGIN_]AS_TR_CPP([$1])[__])
+])
+
+define([_MYSQL_REQUIRE_PLUGIN],[
+ ifdef([$2],[
+ ifelse($2, [$1], [], [
+ AC_FATAL([Misspelt MYSQL_PLUGIN declaration for $1])
+ ])
+ ],[
+ AC_FATAL([Missing MYSQL_PLUGIN declaration for $1])
+ ])
+])
+
+
+dnl ---------------------------------------------------------------------------
+
+
+dnl SYNOPSIS
+dnl _MYSQL_EMIT_METAPLUGINS([name,name...])
+dnl
+dnl DESCRIPTION
+dnl Emits shell code for metaplugins
+
+AC_DEFUN([_MYSQL_EMIT_METAPLUGINS], [ifelse($#, 0, [], $#, 1,
+[_MYSQL_EMIT_METAPLUGIN([$1], [__mysql_]m4_bpatsubst($1, -, _)[_plugins__])
+],
+[_MYSQL_EMIT_METAPLUGIN([$1], [__mysql_]m4_bpatsubst($1, -, _)[_plugins__])
+_MYSQL_EMIT_METAPLUGINS(m4_shift($@))])
+])
+
+AC_DEFUN([_MYSQL_EMIT_METAPLUGIN], [
+ [$1] )
+m4_ifdef([$2], [
+ mysql_plugins='m4_bpatsubst($2, :, [ ])'
+],[
+ mysql_plugins=''
+])
+ ;;
+])
+
+
+dnl ---------------------------------------------------------------------------
+
+
+dnl SYNOPSIS
+dnl _MYSQL_PLUGAPPEND([name],[to-append])
+dnl
+dnl DESCRIPTION
+dnl Helper macro for appending to colon-delimited lists
+dnl Optinal 3rd argument is for actions only required when defining
+dnl macro named for the first time.
+
+AC_DEFUN([_MYSQL_PLUGAPPEND],[
+ m4_ifdef([$1],[
+ m4_define([__plugin_append_tmp__], m4_defn([$1]))
+ m4_undefine([$1])
+ m4_define([$1], __plugin_append_tmp__[:$2])
+ m4_undefine([__plugin_append_tmp__])
+ ],[
+ m4_define([$1], [$2])
+ $3
+ ])
+])
+
+
+dnl SYNOPSIS
+dnl _MYSQL_PLUGAPPEND_META([name],[meta,meta...])
+dnl
+dnl DESCRIPTION
+dnl Helper macro for adding plugins to meta plugins
+
+AC_DEFUN([_MYSQL_PLUGAPPEND_META],[
+ ifelse($#, 1, [], [$#:$2], [2:], [], [$2], [all], [
+ AC_FATAL([protected plugin group: all])
+ ], [$2], [none], [
+ AC_FATAL([protected plugin group: none])
+ ],[
+ _MYSQL_PLUGAPPEND([__mysql_$1_configs__],[$2])
+ _MYSQL_PLUGAPPEND([__mysql_]m4_bpatsubst($2, -, _)[_plugins__],[$1], [
+ _MYSQL_PLUGAPPEND([__mysql_metaplugin_list__],[$2])
+ ])
+ _MYSQL_PLUGAPPEND_META([$1], m4_shift(m4_shift($@)))
+ ])
+])
+
+
+dnl ---------------------------------------------------------------------------
+
+
+dnl SYNOPSIS
+dnl MYSQL_LIST_PLUGINS
+dnl
+dnl DESCRIPTION
+dnl Emits formatted list of declared plugins
+
+AC_DEFUN([MYSQL_LIST_PLUGINS],[dnl
+ m4_ifdef([__mysql_plugin_list__],[dnl
+ _MYSQL_LIST_PLUGINS(m4_bpatsubst(__mysql_plugin_list__, :, [,]))dnl
+ ])dnl
+])
+
+AC_DEFUN([_MYSQL_LIST_PLUGINS],[dnl
+ ifelse($#, 0, [], $#, 1, [dnl
+ MYSQL_SHOW_PLUGIN([$1])dnl
+ ],[dnl
+ MYSQL_SHOW_PLUGIN([$1])dnl
+ _MYSQL_LIST_PLUGINS(m4_shift($@))dnl
+ ])dnl
+])
+
+AC_DEFUN([MYSQL_SHOW_PLUGIN],[
+ _MYSQL_SHOW_PLUGIN(
+ [$1],
+ [$1-plugin],
+ [MYSQL_PLUGIN_NAME_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DESC_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DEFINE_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DIRECTORY_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_STATIC_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DYNAMIC_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_MANDATORY_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DISABLED_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_ACTIONS_]AS_TR_CPP([$1]),
+ __mysql_[$1]_configs__,
+ )
+])
+
+AC_DEFUN([_MYSQL_SHOW_PLUGIN],[dnl
+ === $3 ===
+ Plugin Name: [$1]
+ Description: $4
+ Supports build: _PLUGIN_BUILD_TYPE([$7],[$8])[]dnl
+m4_ifdef([$12],[
+ Configurations: m4_bpatsubst($12, :, [, ])])[]dnl
+m4_ifdef([$10],[
+ Status: disabled])[]dnl
+m4_ifdef([$9],[
+ Status: mandatory])[]dnl
+])
+
+AC_DEFUN([_PLUGIN_BUILD_TYPE],
+[m4_ifdef([$1],[static ]m4_ifdef([$2],[and dnl
+]))[]m4_ifdef([$2],[dynamic],[m4_ifdef([$1],[],[static])])])
+
+
+dnl ---------------------------------------------------------------------------
+
+
+AC_DEFUN([_MYSQL_EMIT_PLUGINS],[
+ ifelse($#, 0, [], [$#:$1], [1:], [], [
+ m4_ifdef([MYSQL_PLUGIN_ACTIONS_]AS_TR_CPP([$1]), [], [
+ m4_define([MYSQL_PLUGIN_ACTIONS_]AS_TR_CPP([$1]),[ ])
+ ])
+ [$1] )
+ m4_ifdef([MYSQL_PLUGIN_DISABLED_]AS_TR_CPP([$1]),[
+ AC_MSG_ERROR([plugin $1 is disabled])
+ ],[
+ _MYSQL_EMIT_PLUGIN_ENABLE([$1], m4_bpatsubst([$1], -, _),
+ [MYSQL_PLUGIN_NAME_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_STATIC_]AS_TR_CPP([$1]),
+ [MYSQL_PLUGIN_DYNAMIC_]AS_TR_CPP([$1]))
+ ])
+ ;;
+ _MYSQL_EMIT_PLUGINS(m4_shift($@))
+ ])
+])
+
+AC_DEFUN([_MYSQL_EMIT_PLUGIN_ENABLE],[
+ m4_ifdef([$5],m4_ifdef([$4],[
+ [mysql_plugin_]$2=yes
+ ],[
+ AC_MSG_WARN([$3 can only be built as a plugin])
+ ]),[
+ [mysql_plugin_]$2=yes
+ ])
+])
+
+AC_DEFUN([_MYSQL_EMIT_PLUGIN_DEPENDS], [
+ ifelse($#, 0, [], [$#:$1], [1:], [], [
+ _MYSQL_EMIT_CHECK_DEPENDS(m4_bpatsubst([$1], -, _),
+ [__mysql_plugdepends_$1__])
+ _MYSQL_EMIT_PLUGIN_DEPENDS(m4_shift($@))
+ ])
+])
+
+AC_DEFUN([_MYSQL_EMIT_CHECK_DEPENDS], [
+ m4_ifdef([$2], [
+ if test "X[$mysql_plugin_]$1" = Xyes -a \
+ "X[$with_plugin_]$1" != Xno -o \
+ "X[$with_plugin_]$1" = Xyes; then
+ _MYSQL_EMIT_PLUGIN_DEPENDENCIES(m4_bpatsubst($2, :, [,]))
+ fi
+ ])
+])
+
+AC_DEFUN([_MYSQL_EMIT_PLUGIN_DEPENDENCIES], [
+ ifelse([$1], [], [], [
+ m4_ifdef([MYSQL_PLUGIN_DISABLED_]AS_TR_CPP([$1]),[
+ AC_MSG_ERROR([depends upon disabled plugin $1])
+ ],[
+ [mysql_plugin_]m4_bpatsubst([$1], -, _)=yes
+ if test "X[$with_plugin_]m4_bpatsubst([$1], -, _)" = Xno; then
+ AC_MSG_ERROR([depends upon disabled plugin $1])
+ fi
+ ])
+ _MYSQL_EMIT_PLUGIN_DEPENDENCIES(m4_shift($@))
+ ])
+])
+
+dnl SYNOPSIS
+dnl _MYSQL_CHECK_PLUGIN_ARGS([plugin],[plugin]...)
+dnl
+dnl DESCRIPTION
+dnl Emits shell script for checking configure arguments
+dnl Arguments to this macro is default value for selected plugins
+
+AC_DEFUN([_MYSQL_CHECK_PLUGIN_ARGS],[
+ __MYSQL_CHECK_PLUGIN_ARGS(m4_default([$1], [none]))
+])
+
+AC_DEFUN([__MYSQL_CHECK_PLUGIN_ARGS],[
+ AC_ARG_WITH([plugins],
+AS_HELP_STRING([--with-plugins=PLUGIN[[[[[,PLUGIN..]]]]]],
+ [Plugins to include in mysqld. (default is: $1) Must be a
+ configuration name or a comma separated list of plugins.])
+AS_HELP_STRING([],
+ [Available configurations are:] dnl
+m4_bpatsubst([none:]m4_ifdef([__mysql_metaplugin_list__],
+ __mysql_metaplugin_list__:)[all], :, [ ])[.])
+AS_HELP_STRING([],
+ [Available plugins are:] dnl
+m4_bpatsubst(__mysql_plugin_list__, :, [ ])[.])
+AS_HELP_STRING([--without-plugin-PLUGIN],
+ [Disable the named plugin from being built. Otherwise, for
+ plugins which are not selected for inclusion in mysqld will be
+ built dynamically (if supported)])
+AS_HELP_STRING([--with-plugin-PLUGIN],
+ [Forces the named plugin to be linked into mysqld statically.]),
+ [mysql_plugins="`echo $withval | tr ',.:;*[]' ' '`"],
+ [mysql_plugins=['$1']])
+
+m4_divert_once([HELP_VAR_END],[
+Description of plugins:
+MYSQL_LIST_PLUGINS])
+
+ case "$mysql_plugins" in
+ all )
+ mysql_plugins='m4_bpatsubst(__mysql_plugin_list__, :, [ ])'
+ ;;
+ none )
+ mysql_plugins=''
+ ;;
+m4_ifdef([__mysql_metaplugin_list__],[
+_MYSQL_EMIT_METAPLUGINS(m4_bpatsubst(__mysql_metaplugin_list__, :, [,]))
+])
+ esac
+
+ for plugin in $mysql_plugins; do
+ case "$plugin" in
+ all | none )
+ AC_MSG_ERROR([bad plugin name: $plugin])
+ ;;
+_MYSQL_EMIT_PLUGINS(m4_bpatsubst(__mysql_plugin_list__, :, [,]))
+ * )
+ AC_MSG_ERROR([unknown plugin: $plugin])
+ ;;
+ esac
+ done
+
+ _MYSQL_EMIT_PLUGIN_DEPENDS(m4_bpatsubst(__mysql_plugin_list__, :, [,]))
+])
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: _MYSQL_INCLUDE_LIST
+dnl
+dnl SYNOPSIS
+dnl _MYSQL_INCLUDE_LIST([filename,filename...])
+dnl
+dnl DESCRIPTION
+dnl includes all files from the list
+dnl
+dnl ---------------------------------------------------------------------------
+AC_DEFUN([_MYSQL_INCLUDE_LIST],[
+ ifelse([$1], [], [], [
+ m4_define([__mysql_include__],[$1])
+ dnl We have to use builtin(), because sinclude would generate an error
+ dnl "file $1 does not exists" in aclocal-1.8 - which is a bug, clearly
+ dnl violating m4 specs, and which is fixed in aclocal-1.9
+ builtin([include],$1)
+ m4_undefine([__mysql_include__])
+ _MYSQL_INCLUDE_LIST(m4_shift($@))
+ ])
+])
+
+dnl ===========================================================================
diff --git a/config/ac-macros/ssl.m4 b/config/ac-macros/ssl.m4
new file mode 100644
index 00000000000..729115ffe88
--- /dev/null
+++ b/config/ac-macros/ssl.m4
@@ -0,0 +1,210 @@
+dnl ===========================================================================
+dnl Support for SSL
+dnl ===========================================================================
+dnl
+dnl
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_USE_BUNDLED_YASSL
+dnl
+dnl SYNOPSIS
+dnl MYSQL_USE_BUNDLED_YASSL()
+dnl
+dnl DESCRIPTION
+dnl Add defines so yassl is built and linked with
+dnl ---------------------------------------------------------------------------
+AC_DEFUN([MYSQL_USE_BUNDLED_YASSL], [
+
+ with_bundled_yassl="yes"
+
+ yassl_dir="yassl"
+ AC_SUBST([yassl_dir])
+
+ yassl_libs="\$(top_builddir)/extra/yassl/src/libyassl.la \
+ \$(top_builddir)/extra/yassl/taocrypt/src/libtaocrypt.la"
+ AC_SUBST(yassl_libs)
+
+ AC_DEFINE([HAVE_OPENSSL], [1], [Defined by configure. Using yaSSL for SSL.])
+ AC_DEFINE([HAVE_YASSL], [1], [Defined by configure. Using yaSSL for SSL.])
+
+ # System specific checks
+ yassl_integer_extra_cxxflags=""
+ case $host_cpu--$CXX_VERSION in
+ sparc*--*Sun*C++*5.6*)
+ # Disable inlining when compiling taocrypt/src/
+ yassl_taocrypt_extra_cxxflags="+d"
+ AC_MSG_NOTICE([disabling inlining for yassl/taocrypt/src/])
+ ;;
+ esac
+ AC_SUBST([yassl_taocrypt_extra_cxxflags])
+
+ # Link extra/yassl/include/openssl subdir to include/
+ yassl_h_ln_cmd="\$(LN) -s \$(top_srcdir)/extra/yassl/include/openssl openssl"
+ AC_SUBST(yassl_h_ln_cmd)
+
+ AC_MSG_RESULT([using bundled yaSSL])
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_CHECK_SSL_DIR
+dnl
+dnl SYNOPSIS
+dnl MYSQL_CHECK_SSL_DIR(includes, libs)
+dnl
+dnl DESCRIPTION
+dnl Auxiliary macro to check for ssl at given path
+dnl
+dnl ---------------------------------------------------------------------------
+
+AC_DEFUN([MYSQL_CHECK_SSL_DIR], [
+ssl_incs="$1"
+ssl_libs="$2"
+save_CPPFLAGS="$CPPFLAGS"
+save_LIBS="$LIBS"
+CPPFLAGS="$ssl_incs $CPPFLAGS"
+LIBS="$LIBS $ssl_libs"
+AC_TRY_LINK([#include <openssl/ssl.h>],
+ [return SSL_library_init();],
+ [mysql_ssl_found="yes"],
+ [mysql_ssl_found="no"])
+CPPFLAGS="$save_CPPFLAGS"
+LIBS="$save_LIBS"
+])
+
+
+dnl ---------------------------------------------------------------------------
+dnl Macro: MYSQL_FIND_OPENSSL
+dnl
+dnl SYNOPSIS
+dnl MYSQL_FIND_OPENSSL(location)
+dnl
+dnl DESCRIPTION
+dnl Search the location for OpenSSL support
+dnl
+dnl ---------------------------------------------------------------------------
+AC_DEFUN([MYSQL_FIND_OPENSSL], [
+ location="$1"
+
+ #
+ # Set include paths
+ #
+ openssl_include="$location/include"
+ openssl_includes=""
+
+ # Don't set ssl_includes to /usr/include as this gives us a lot of
+ # compiler warnings when using gcc 3.x
+ if test "$openssl_include" != "/usr/include"
+ then
+ openssl_includes="-I$openssl_include"
+ fi
+
+ #
+ # Try to link with openSSL libs in <location>
+ #
+ openssl_libs="-L$location/lib/ -lssl -lcrypto"
+ MYSQL_CHECK_SSL_DIR([$openssl_includes], [$openssl_libs])
+
+ if test "$mysql_ssl_found" == "no"
+ then
+ #
+ # BUG 764: Compile failure with OpenSSL on Red Hat Linux (krb5.h missing)
+ # Try to link with include paths to kerberos set
+ #
+ openssl_includes="$openssl_includes -I/usr/kerberos/include"
+ MYSQL_CHECK_SSL_DIR([$openssl_includes], [$openssl_libs])
+ fi
+
+ if test "$mysql_ssl_found" == "no"
+ then
+ AC_MSG_ERROR([Could not link with SSL libs at $location])
+ fi
+
+ # openssl-devel-0.9.6 requires dlopen() and we can't link staticly
+ # on many platforms (We should actually test this here, but it's quite
+ # hard to do as we are doing libtool for linking.)
+ case "$CLIENT_EXTRA_LDFLAGS $MYSQLD_EXTRA_LDFLAGS" in
+ *-all-static*)
+ AC_MSG_ERROR([You can't use the --all-static link option when using openssl.])
+ ;;
+ esac
+
+ AC_SUBST(openssl_includes)
+ AC_SUBST(openssl_libs)
+
+ NON_THREADED_CLIENT_LIBS="$NON_THREADED_CLIENT_LIBS $openssl_libs"
+
+ AC_DEFINE([HAVE_OPENSSL], [1], [OpenSSL])
+ AC_MSG_RESULT([using openSSL from $location])
+])
+
+
+
+dnl ------------------------------------------------------------------------
+dnl Macro: MYSQL_CHECK_SSL
+dnl
+dnl SYNOPSIS
+dnl MYSQL_CHECK_SSL
+dnl
+dnl Provides the following configure options:
+dnl --with-ssl=DIR
+dnl Possible DIR values are:
+dnl - no - the macro will disable use of ssl
+dnl - bundled, empty or not specified - means use ssl lib
+dnl bundled along with MySQL sources
+dnl - ssl location prefix - given location prefix, the macro expects
+dnl to find the header files in $prefix/include/, and libraries in
+dnl $prefix/lib. If headers or libraries weren't found at $prefix, the
+dnl macro bails out with error.
+dnl
+dnl ------------------------------------------------------------------------
+AC_DEFUN([MYSQL_CHECK_SSL], [
+
+ AC_CONFIG_FILES(extra/yassl/Makefile dnl
+ extra/yassl/taocrypt/Makefile dnl
+ extra/yassl/taocrypt/benchmark/Makefile dnl
+ extra/yassl/taocrypt/src/Makefile dnl
+ extra/yassl/taocrypt/test/Makefile dnl
+ extra/yassl/src/Makefile dnl
+ extra/yassl/testsuite/Makefile)
+
+AC_MSG_CHECKING(for SSL)
+ AC_ARG_WITH([ssl],
+ [ --with-ssl[=DIR] Include SSL support],
+ [mysql_ssl_dir="$withval"],
+ [mysql_ssl_dir=no])
+
+ if test "$with_yassl"
+ then
+ AC_MSG_ERROR([The flag --with-yassl is deprecated, use --with-ssl])
+ fi
+
+ if test "$with_openssl"
+ then
+ AC_MSG_ERROR([The flag --with-openssl is deprecated, use --with-ssl])
+ fi
+
+ case "$mysql_ssl_dir" in
+ "no")
+ #
+ # Don't include SSL support
+ #
+ AC_MSG_RESULT([disabled])
+ ;;
+
+ "bundled"|"yes")
+ #
+ # Use the bundled SSL implementation (yaSSL)
+ #
+ MYSQL_USE_BUNDLED_YASSL
+ ;;
+
+ *)
+ #
+ # A location where to search for OpenSSL was specified
+ #
+ MYSQL_FIND_OPENSSL([$mysql_ssl_dir])
+ ;;
+ esac
+ AM_CONDITIONAL([HAVE_YASSL], [ test "$with_bundled_yassl" = "yes" ])
+])
diff --git a/config/ac-macros/yassl.m4 b/config/ac-macros/yassl.m4
deleted file mode 100644
index 967dcbf764a..00000000000
--- a/config/ac-macros/yassl.m4
+++ /dev/null
@@ -1,45 +0,0 @@
-AC_CONFIG_FILES(extra/yassl/Makefile dnl
-extra/yassl/taocrypt/Makefile dnl
-extra/yassl/taocrypt/src/Makefile dnl
-extra/yassl/src/Makefile dnl
-extra/yassl/testsuite/Makefile dnl
-extra/yassl/taocrypt/test/Makefile dnl
-extra/yassl/taocrypt/benchmark/Makefile)
-
-AC_DEFUN([MYSQL_CHECK_YASSL], [
- AC_MSG_CHECKING(for yaSSL)
- AC_ARG_WITH([yassl], [ --with-yassl Include the yaSSL support],,)
-
- if test "$with_yassl" = "yes"
- then
- if test "$openssl" != "no"
- then
- AC_MSG_ERROR([Cannot configure MySQL to use yaSSL and OpenSSL simultaneously.])
- fi
- AC_MSG_RESULT([using bundled yaSSL])
- yassl_dir="extra/yassl"
- yassl_libs="\$(top_builddir)/extra/yassl/src/libyassl.la \
- \$(top_builddir)/extra/yassl/taocrypt/src/libtaocrypt.la"
- AC_DEFINE([HAVE_OPENSSL], [1], [Defined by configure. Using yaSSL for OpenSSL emulation.])
- AC_DEFINE([HAVE_YASSL], [1], [Defined by configure. Using yaSSL for OpenSSL emulation.])
- # System specific checks
- yassl_integer_extra_cxxflags=""
- case $host_cpu--$CXX_VERSION in
- sparc*--*Sun*C++*5.6*)
- # Disable inlining when compiling taocrypt/src/
- yassl_taocrypt_extra_cxxflags="+d"
- AC_MSG_NOTICE([disabling inlining for yassl/taocrypt/src/])
- ;;
- esac
- AC_SUBST([yassl_taocrypt_extra_cxxflags])
- # Link extra/yassl/include/openssl subdir to include/
- yassl_h_ln_cmd="\$(LN) -s \$(top_srcdir)/extra/yassl/include/openssl openssl"
- AC_SUBST(yassl_h_ln_cmd)
- else
- yassl_dir=""
- AC_MSG_RESULT(no)
- fi
- AC_SUBST(yassl_libs)
- AC_SUBST(yassl_dir)
- AM_CONDITIONAL([HAVE_YASSL], [ test "$with_yassl" = "yes" ])
-])
diff --git a/config/ac-macros/zlib.m4 b/config/ac-macros/zlib.m4
index 5defdfd6749..f62bb056249 100644
--- a/config/ac-macros/zlib.m4
+++ b/config/ac-macros/zlib.m4
@@ -64,6 +64,9 @@ dnl installation dir ($pkglibdir), so ZLIB_DEPS is set to point to
dnl $pkglibdir.
AC_DEFUN([MYSQL_CHECK_ZLIB_WITH_COMPRESS], [
+
+AC_CONFIG_FILES(zlib/Makefile)
+
AC_MSG_CHECKING([for zlib compression library])
case $SYSTEM_TYPE in
*netware* | *modesto*)
@@ -72,7 +75,7 @@ case $SYSTEM_TYPE in
;;
*)
AC_ARG_WITH([zlib-dir],
- AC_HELP_STRING([--with-zlib-dir=DIR],
+ AC_HELP_STRING([--with-zlib-dir=no|bundled|DIR],
[Provide MySQL with a custom location of
compression library. Given DIR, zlib binary is
assumed to be in $DIR/lib and header files