AC_MSG_CHECKING(for MySQL support)
AC_ARG_WITH(mysql,
[
- --with-mysql[=DIR] Include MySQL support. DIR is the MySQL base
+ --with-mysql@<:@=DIR@:>@ Include MySQL support. DIR is the MySQL base
install directory, default is to search through
a number of common places for the MySQL files.],
[
if test "$withval" = "yes"; then
if test -f /usr/local/mysql/include/mysql/mysql.h; then
MYSQL_INCDIR=/usr/local/mysql/include/mysql
- if test -f /usr/local/mysql/lib64/mysql/libmysqlclient.a; then
+ if test -f /usr/local/mysql/lib64/mysql/libmysqlclient_r.a \
+ -o -f /usr/local/mysql/lib64/mysql/libmysqlclient_r.so; then
MYSQL_LIBDIR=/usr/local/mysql/lib64/mysql
else
MYSQL_LIBDIR=/usr/local/mysql/lib/mysql
MYSQL_BINDIR=/usr/local/mysql/bin
elif test -f /usr/include/mysql/mysql.h; then
MYSQL_INCDIR=/usr/include/mysql
- if test -f /usr/lib64/mysql/libmysqlclient.a; then
+ if test -f /usr/lib64/mysql/libmysqlclient_r.a \
+ -o -f /usr/lib64/mysql/libmysqlclient_r.so; then
MYSQL_LIBDIR=/usr/lib64/mysql
- else
+ elif test -f /usr/lib/mysql/libmysqlclient_r.a \
+ -o -f /usr/lib/mysql/libmysqlclient_r.so; then
MYSQL_LIBDIR=/usr/lib/mysql
+ else
+ MYSQL_LIBDIR=/usr/lib
fi
MYSQL_BINDIR=/usr/bin
elif test -f /usr/include/mysql.h; then
MYSQL_INCDIR=/usr/include
- if test -f /usr/lib64/libmysqlclient.a; then
+ if test -f /usr/lib64/libmysqlclient_r.a \
+ -o -f /usr/lib64/libmysqlclient_r.so; then
MYSQL_LIBDIR=/usr/lib64
else
MYSQL_LIBDIR=/usr/lib
MYSQL_BINDIR=/usr/bin
elif test -f /usr/local/include/mysql/mysql.h; then
MYSQL_INCDIR=/usr/local/include/mysql
- if test -f /usr/local/lib64/mysql/libmysqlclient.a; then
+ if test -f /usr/local/lib64/mysql/libmysqlclient_r.a \
+ -o -f /usr/local/lib64/mysql/libmysqlclient_r.so; then
MYSQL_LIBDIR=/usr/local/lib64/mysql
else
MYSQL_LIBDIR=/usr/local/lib/mysql
MYSQL_BINDIR=/usr/local/bin
elif test -f /usr/local/include/mysql.h; then
MYSQL_INCDIR=/usr/local/include
- if test -f /usr/local/lib64/libmysqlclient.a; then
+ if test -f /usr/local/lib64/libmysqlclient_r.a \
+ -o -f /usr/local/lib64/libmysqlclient_r.so; then
MYSQL_LIBDIR=/usr/local/lib64
else
MYSQL_LIBDIR=/usr/local/lib
else
if test -f $withval/include/mysql/mysql.h; then
MYSQL_INCDIR=$withval/include/mysql
- if test -f $withval/lib64/mysql/libmysqlclient.a; then
+ if test -f $withval/lib64/mysql/libmysqlclient_r.a \
+ -o -f $withval/lib64/mysql/libmysqlclient_r.so; then
MYSQL_LIBDIR=$withval/lib64/mysql
else
MYSQL_LIBDIR=$withval/lib/mysql
# Solaris ...
- if test -f $withval/lib/libmysqlclient.so; then
+ if test -f $withval/lib/libmysqlclient_r.so; then
MYSQL_LIBDIR=$withval/lib
fi
fi
MYSQL_BINDIR=$withval/bin
elif test -f $withval/include/mysql.h; then
MYSQL_INCDIR=$withval/include
- if test -f "$withval/lib64/libmysqlclient.a"; then
+ if test -f $withval/lib64/libmysqlclient_r.a \
+ -o -f $withval/lib64/libmysqlclient_r.so; then
MYSQL_LIBDIR=$withval/lib64
else
MYSQL_LIBDIR=$withval/lib
fi
fi
SQL_INCLUDE=-I$MYSQL_INCDIR
- if test -f "$MYSQL_LIBDIR/libmysqlclient_r.a"; then
+ if test -f $MYSQL_LIBDIR/libmysqlclient_r.a \
+ -o -f $MYSQL_LIBDIR/libmysqlclient_r.so; then
SQL_LFLAGS="-L$MYSQL_LIBDIR -lmysqlclient_r -lz"
AC_DEFINE(HAVE_THREAD_SAFE_MYSQL)
- else
- SQL_LFLAGS="-L$MYSQL_LIBDIR -lmysqlclient -lz"
fi
SQL_BINDIR=$MYSQL_BINDIR
+ SQL_LIB=$MYSQL_LIBDIR/libmysqlclient_r.a
AC_DEFINE(HAVE_MYSQL)
AC_MSG_RESULT(yes)
db_found=yes
support_mysql=yes
- db_name=MySQL
- DB_NAME=mysql
+ db_type=MySQL
+ DB_TYPE=mysql
else
AC_MSG_RESULT(no)
AC_ARG_WITH(embedded-mysql,
[
- --with-embedded-mysql[=DIR] Include MySQL support. DIR is the MySQL base
+ --with-embedded-mysql@<:@=DIR@:>@ Include MySQL support. DIR is the MySQL base
install directory, default is to search through
a number of common places for the MySQL files.],
[
SQL_INCLUDE=-I$MYSQL_INCDIR
SQL_LFLAGS="-L$MYSQL_LIBDIR -lmysqld -lz -lm -lcrypt"
SQL_BINDIR=$MYSQL_BINDIR
+ SQL_LIB=$MYSQL_LIBDIR/libmysqld.a
AC_DEFINE(HAVE_MYSQL)
AC_DEFINE(HAVE_EMBEDDED_MYSQL)
AC_MSG_RESULT(yes)
db_found=yes
support_mysql=yes
- db_name=MySQL
- DB_NAME=mysql
+ db_type=MySQL
+ DB_TYPE=mysql
else
AC_MSG_RESULT(no)
AC_MSG_CHECKING(for SQLite support)
AC_ARG_WITH(sqlite,
[
- --with-sqlite[=DIR] Include SQLite support. DIR is the SQLite base
+ --with-sqlite@<:@=DIR@:>@ Include SQLite support. DIR is the SQLite base
install directory, default is to search through
a number of common places for the SQLite files.],
[
SQL_INCLUDE=-I$SQLITE_INCDIR
SQL_LFLAGS="-L$SQLITE_LIBDIR -lsqlite"
SQL_BINDIR=$SQLITE_BINDIR
+ SQL_LIB=$SQLITE_LIBDIR/libsqlite.a
AC_DEFINE(HAVE_SQLITE)
AC_MSG_RESULT(yes)
db_found=yes
support_sqlite=yes
- db_name=SQLite
- DB_NAME=sqlite
+ db_type=SQLite
+ DB_TYPE=sqlite
else
AC_MSG_RESULT(no)
AC_MSG_CHECKING(for SQLite3 support)
AC_ARG_WITH(sqlite3,
[
- --with-sqlite3[=DIR] Include SQLite3 support. DIR is the SQLite3 base
+ --with-sqlite3@<:@=DIR@:>@ Include SQLite3 support. DIR is the SQLite3 base
install directory, default is to search through
a number of common places for the SQLite3 files.],
[
SQL_INCLUDE=-I$SQLITE_INCDIR
SQL_LFLAGS="-L$SQLITE_LIBDIR -lsqlite3"
SQL_BINDIR=$SQLITE_BINDIR
+ SQL_LIB=$SQLITE_LIBDIR/libsqlite3.a
AC_DEFINE(HAVE_SQLITE3)
AC_MSG_RESULT(yes)
db_found=yes
support_sqlite3=yes
- db_name=SQLite3
- DB_NAME=sqlite3
+ db_type=SQLite3
+ DB_TYPE=sqlite3
else
AC_MSG_RESULT(no)
db_found=no
AC_MSG_CHECKING(for PostgreSQL support)
AC_ARG_WITH(postgresql,
-[ --with-postgresql[=DIR] Include PostgreSQL support. DIR is the PostgreSQL
+[ --with-postgresql@<:@=DIR@:>@ Include PostgreSQL support. DIR is the PostgreSQL
base install directory, defaults to /usr/local/pgsql],
[
if test "$withval" != "no"; then
SQL_INCLUDE=-I$POSTGRESQL_INCDIR
SQL_LFLAGS=$POSTGRESQL_LFLAGS
SQL_BINDIR=$POSTGRESQL_BINDIR
+ SQL_LIB=$POSTGRESQL_LIBDIR/libpq.a
+
AC_DEFINE(HAVE_POSTGRESQL)
AC_MSG_RESULT(yes)
db_found=yes
support_postgresql=yes
- db_name=PostgreSQL
- DB_NAME=postgresql
+ db_type=PostgreSQL
+ DB_TYPE=postgresql
else
AC_MSG_RESULT(no)
fi
dnl Check for some DBMS backend
dnl NOTE: we can use only one backend at a time
db_found=no
-db_name=none
+DB_TYPE=none
if test x$support_mysql = xyes; then
cats=cats
AC_MSG_CHECKING(for Berkeley DB support)
AC_ARG_WITH(berkeleydb,
[
- --with-berkeleydb[=DIR] Include Berkeley DB support. DIR is the Berkeley DB base
+ --with-berkeleydb@<:@=DIR@:>@ Include Berkeley DB support. DIR is the Berkeley DB base
install directory, default is to search through
a number of common places for the DB files.],
[
AC_MSG_RESULT(yes)
have_db=yes
support_mysql=yes
- db_name=BerkelyDB
+ DB_TYPE=BerkelyDB
else
AC_MSG_RESULT(no)
AC_MSG_CHECKING(for mSQL support)
AC_ARG_WITH(msql,
-[ --with-msql[=DIR] Include mSQL support. DIR is the mSQL base
+[ --with-msql@<:@=DIR@:> Include mSQL support. DIR is the mSQL base
install directory, defaults to /usr/local/Hughes.],
[
if test "$withval" != "no"; then
AC_MSG_CHECKING(for iODBC support)
AC_ARG_WITH(iodbc,
-[ --with-iodbc[=DIR] Include iODBC support. DIR is the iODBC base
+[ --with-iodbc@<:@=DIR@:> Include iODBC support. DIR is the iODBC base
install directory, defaults to /usr/local.],
[
if test "$withval" != "no"; then
AC_MSG_CHECKING(for unixODBC support)
AC_ARG_WITH(unixODBC,
-[ --with-unixODBC[=DIR] Include unixODBC support. DIR is the unixODBC base
+[ --with-unixODBC@<:@=DIR@:> Include unixODBC support. DIR is the unixODBC base
install directory, defaults to /usr/local.],
[
if test "$withval" != "no"; then
AC_MSG_CHECKING(for Solid support)
AC_ARG_WITH(solid,
-[ --with-solid[=DIR] Include Solid support. DIR is the Solid base
+[ --with-solid@<:@=DIR@:> Include Solid support. DIR is the Solid base
install directory, defaults to /usr/local.],
[
if test "$withval" != "no"; then
AC_MSG_CHECKING(for OpenLink ODBC support)
AC_ARG_WITH(openlink,
-[ --with-openlink[=DIR] Include OpenLink ODBC support.
+[ --with-openlink@<:@=DIR@:> Include OpenLink ODBC support.
DIR is the base OpenLink ODBC install directory],
[
if test "$withval" != "no"; then
AC_MSG_CHECKING(for EasySoft ODBC support)
AC_ARG_WITH(easysoft,
-[ --with-easysoft[=DIR] Include EasySoft ODBC support.
+[ --with-easysoft@<:@=DIR@:> Include EasySoft ODBC support.
DIR is the base EasySoft ODBC install directory],
[
if test "$withval" != "no"; then
AC_MSG_CHECKING(for InterBase support)
AC_ARG_WITH(ibase,
-[ --with-ibase[=DIR] Include InterBase support. DIR is the InterBase
+[ --with-ibase@<:@=DIR@:> Include InterBase support. DIR is the InterBase
install directory, defaults to /usr/interbase.],
[
if test "$withval" != "no"; then
AC_MSG_CHECKING(for Oracle8 support)
AC_ARG_WITH(oracle8,
-[ --with-oracle8[=DIR] Include Oracle8 support. DIR is the Oracle
+[ --with-oracle8@<:@=DIR@:> Include Oracle8 support. DIR is the Oracle
home directory, defaults to $ORACLE_HOME or
/oracle8/app/oracle/product/8.0.5.],
[
AC_MSG_CHECKING(for Oracle7 support)
AC_ARG_WITH(oracle7,
-[ --with-oracle7[=DIR] Include Oracle 7.3 support. DIR is the Oracle
+[ --with-oracle7@<:@=DIR@:> Include Oracle 7.3 support. DIR is the Oracle
home directory, defaults to
ORACLE_HOME [$ORACLE_HOME]],
[