diff options
| -rw-r--r-- | Changes | 1 | ||||
| -rw-r--r-- | aclocal.m4 | 169 | ||||
| -rw-r--r-- | anope.m4 | 31 | ||||
| -rwxr-xr-x | configure | 2349 | ||||
| -rw-r--r-- | configure.in | 47 | ||||
| -rw-r--r-- | mysql.m4 | 142 | ||||
| -rw-r--r-- | version.log | 6 |
7 files changed, 2074 insertions, 671 deletions
@@ -23,6 +23,7 @@ Provided by Anope Dev. <dev@anope.org> - 2006 06/13 F Added cleanup code to tools/anopesmtp. [#464] 06/13 F Fixed a lot of redundant function declarations. [#510] 06/14 F Removed last traces of threading support. [#498] +06/14 F Changed mysql detection to use mysql_config. [ #00] Provided by ThaPrince <jon@vile.com> - 2006 05/19 A Plexus 3 support. [ #00] diff --git a/aclocal.m4 b/aclocal.m4 index 91daa5730..0d17d95bd 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -829,146 +829,35 @@ test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) AC_LIB_PROG_LD_GNU ]) -# Configure paths for mysql-client, GPLv2 -#$Id$ -#ken restivo modified 2001/08/04 to remove NULLs and use 0, in case NULL undefined. -# Markus Fischer <[EMAIL PROTECTED]>, 23.9.1999 -# URL : http://josefine.ben.tuwien.ac.at/~mfischer/m4/mysql-client.m4 -# Last Modified : Thu Sep 23 14:24:15 CEST 1999 -# -# written from scratch - -dnl Test for libmysqlclient and -dnl define MYSQLCLIENT_CFLAGS, MYSQLCLIENT_LDFLAGS and MYSQLCLIENT_LIBS -dnl usage: -dnl AM_PATH_MYSQLCLIENT( -dnl [MINIMUM-VERSION, -dnl [ACTION-IF-FOUND [, -dnl ACTION-IF-NOT-FOUND ]]]) +dnl Macro: anope_CHECK_TYPE_SIZES dnl - -AC_DEFUN(AM_PATH_MYSQLCLIENT, -[ -AC_ARG_WITH(mysqlclient-prefix, - [ --with-mysqlclient-prefix=PFX Prefix where mysqlclient is -installed], - mysqlclient_prefix="$withval", - mysqlclient_prefix="") - -AC_ARG_WITH(mysqlclient-include, [ --with-mysqlclient-include=DIR Directory pointing - to mysqlclient include files], - mysqlclient_include="$withval", - mysqlclient_include="") - -AC_ARG_WITH(mysqlclient-lib, -[ --with-mysqlclient-lib=LIB Directory pointing to mysqlclient library - (Note: -include and -lib do override - paths found with -prefix) -], - mysqlclient_lib="$withval", - mysqlclient_lib="") - - AC_MSG_CHECKING([for mysqlclient ifelse([$1], , ,[>= v$1])]) - MYSQLCLIENT_LDFLAGS="" - MYSQLCLIENT_CFLAGS="" - MYSQLCLIENT_LIBS="-lmysqlclient" - mysqlclient_fail="" - - dnl test --with-mysqlclient-prefix - for tryprefix in /usr /usr/local /usr/mysql /usr/local/mysql /usr/pkg $msqlclient_prefix; do - #testloop - for hloc in lib/mysql lib ; do - if test -e "$tryprefix/$hloc/libmysqlclient.so"; then - MYSQLCLIENT_LDFLAGS="-L$tryprefix/$hloc" - fi - done - - for iloc in include/mysql include; do - if test -e "$tryprefix/$iloc/mysql.h"; then - MYSQLCLIENT_CFLAGS="-I$tryprefix/$iloc" - fi - done - # testloop - done - - dnl test --with-mysqlclient-include - if test "x$mysqlclient_include" != "x" ; then - echo "checking for mysql includes... " - if test -d "$mysqlclient_include/mysql" ; then - MYSQLCLIENT_CFLAGS="-I$mysqlclient_include" - echo " found $MYSQLCLIENT_CFLAGS" - elif test -d "$mysqlclient_include/include/mysql" ; then - MYSQLCLIENT_CFLAGS="-I$mysqlclient_include/include" - echo " found $MYSQLCLIENT_CFLAGS" - elif test -d "$mysqlclient_include" ; then - MYSQLCLIENT_CFLAGS="-I$mysqlclient_include" - echo "found $MYSQLCLIENT_CFLAGS" - else - echo "not found! no include dir found in $mysqlclient_include" - fi - fi - - dnl test --with-mysqlclient-lib - if test "x$mysqlclient_lib" != "x" ; then - echo "checking for mysql libx... " - if test -d "$mysqlclient_lib/lib/mysql" ; then - MYSQLCLIENT_LDFLAGS="-L$mysqlclient_lib/lib/mysql" - echo "found $MYSQLCLIENT_LDFLAGS" - elif test -d "$mysqlclient_lib/lin" ; then - MYSQLCLIENT_LDFLAGS="-L$mysqlclient_lib/lib" - echo "found $MYSQLCLIENT_LDFLAGS" - else - MYSQLCLIENT_LDFLAGS="-L$mysqlclient_lib" - echo "defaultd to $MYSQLCLIENT_LDFLAGS" - fi - fi - - ac_save_CFLAGS="$CFLAGS" - ac_save_LDFLAGS="$LDFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="-v $CFLAGS $MYSQLCLIENT_CFLAGS" - LDFLAGS="$LDFLAGS $MYSQLCLIENT_LDFLAGS" - LIBS="$LIBS $MYSQLCLIENT_LIBS" - dnl if no minimum version is given, just try to compile - dnl else try to compile AND run - AC_TRY_COMPILE([ - #include <mysql.h> - #include <mysql_version.h> - ],[ - mysql_connect( 0, 0, 0, 0); - ], [AC_MSG_RESULT(yes $MYSQLCLIENT_CFLAGS $MYSQLCLIENT_LDFLAGS) - CFLAGS="$ac_save_CFLAGS" - LDFLAGS="$ac_save_LDFLAGS" - LIBS="$ac_save_LIBS" - ifelse([$2], ,:,[$2]) - ],[ - echo "no" - echo "can't compile a simple app with mysql_connnect in it. -bad." - mysqlclient_fail="yes" - ]) - - if test "x$mysqlclient_fail" != "x" ; then - dnl AC_MSG_RESULT(no) - echo - echo "***" - echo "*** mysqlclient test source had problems, check your config.log ." - echo "*** Also try one of the following switches :" - echo "*** --with-mysqlclient-prefix=PFX" - echo "*** --with-mysqlclient-include=DIR" - echo "*** --with-mysqlclient-lib=DIR" - echo "***" - CFLAGS="$ac_save_CFLAGS" - LDFLAGS="$ac_save_LDFLAGS" - LIBS="$ac_save_LIBS" - ifelse([$3], ,:,[$3]) - fi - - CFLAGS="$ac_save_CFLAGS" - LDFLAGS="$ac_save_LDFLAGS" - LIBS="$ac_save_LIBS" - AC_SUBST(MYSQLCLIENT_LDFLAGS) - AC_SUBST(MYSQLCLIENT_CFLAGS) - AC_SUBST(MYSQLCLIENT_LIBS) +dnl Check the size of several types and define a valid int16_t and int32_t. +dnl +AC_DEFUN(anope_CHECK_TYPE_SIZES, +[dnl Check type sizes +AC_CHECK_SIZEOF(short) +AC_CHECK_SIZEOF(int) +AC_CHECK_SIZEOF(long) +if test "$ac_cv_sizeof_int" = 2 ; then + AC_CHECK_TYPE(int16_t, int) + AC_CHECK_TYPE(u_int16_t, unsigned int) +elif test "$ac_cv_sizeof_short" = 2 ; then + AC_CHECK_TYPE(int16_t, short) + AC_CHECK_TYPE(u_int16_t, unsigned short) +else + AC_MSG_ERROR([Cannot find a type with size of 16 bits]) +fi +if test "$ac_cv_sizeof_int" = 4 ; then + AC_CHECK_TYPE(int32_t, int) + AC_CHECK_TYPE(u_int32_t, unsigned int) +elif test "$ac_cv_sizeof_short" = 4 ; then + AC_CHECK_TYPE(int32_t, short) + AC_CHECK_TYPE(u_int32_t, unsigned short) +elif test "$ac_cv_sizeof_long" = 4 ; then + AC_CHECK_TYPE(int32_t, long) + AC_CHECK_TYPE(u_int32_t, unsigned long) +else + AC_MSG_ERROR([Cannot find a type with size of 32 bits]) +fi ]) diff --git a/anope.m4 b/anope.m4 new file mode 100644 index 000000000..56e750dd3 --- /dev/null +++ b/anope.m4 @@ -0,0 +1,31 @@ +dnl Macro: anope_CHECK_TYPE_SIZES +dnl +dnl Check the size of several types and define a valid int16_t and int32_t. +dnl +AC_DEFUN(anope_CHECK_TYPE_SIZES, +[dnl Check type sizes +AC_CHECK_SIZEOF(short) +AC_CHECK_SIZEOF(int) +AC_CHECK_SIZEOF(long) +if test "$ac_cv_sizeof_int" = 2 ; then + AC_CHECK_TYPE(int16_t, int) + AC_CHECK_TYPE(u_int16_t, unsigned int) +elif test "$ac_cv_sizeof_short" = 2 ; then + AC_CHECK_TYPE(int16_t, short) + AC_CHECK_TYPE(u_int16_t, unsigned short) +else + AC_MSG_ERROR([Cannot find a type with size of 16 bits]) +fi +if test "$ac_cv_sizeof_int" = 4 ; then + AC_CHECK_TYPE(int32_t, int) + AC_CHECK_TYPE(u_int32_t, unsigned int) +elif test "$ac_cv_sizeof_short" = 4 ; then + AC_CHECK_TYPE(int32_t, short) + AC_CHECK_TYPE(u_int32_t, unsigned short) +elif test "$ac_cv_sizeof_long" = 4 ; then + AC_CHECK_TYPE(int32_t, long) + AC_CHECK_TYPE(u_int32_t, unsigned long) +else + AC_MSG_ERROR([Cannot find a type with size of 32 bits]) +fi +]) @@ -309,7 +309,7 @@ ac_includes_default="\ # include <unistd.h> #endif" -ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT RM CP TOUCH INSTALL CPP EGREP MYSQL RDB MYSQLCLIENT_LDFLAGS MYSQLCLIENT_CFLAGS MYSQLCLIENT_LIBS ANOPELIBS SHARED MODULEFLAGS RUNGROUP BINDEST DATDEST MODULE_PATH LIBOBJS LTLIBOBJS' +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT RM CP TOUCH INSTALL MYSQLCONF MYSQL RDB ANOPELIBS CPP EGREP SHARED MODULEFLAGS RUNGROUP BINDEST DATDEST MODULE_PATH LIBOBJS LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -840,15 +840,8 @@ if test -n "$ac_init_help"; then Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --without-mysql Do not use MySQL even if we find it - --with-mysqlclient-prefix=PFX Prefix where mysqlclient is -installed - --with-mysqlclient-include=DIR Directory pointing - to mysqlclient include files - --with-mysqlclient-lib=LIB Directory pointing to mysqlclient library - (Note: -include and -lib do override - paths found with -prefix) - + --without-mysql Do not use MySQL or attempt to find it + --with-mysqlconfig-path=PATH Complete path to the mysql_config executable --with-rungroup=group Specify the rungroup for anope --with-permissions=permissions Specify the default permissions for anope --with-bindir=bindir Specify the default binary dir for anope @@ -2725,7 +2718,6 @@ if test $ac_cv_lib_bsd_revoke = yes; then ANOPELIBS="$ANOPELIBS-lbsd " fi -x="0"; @@ -2795,6 +2787,97 @@ fi DIS_MYSQL=" MySql: No" + +# Check whether --with-mysql or --without-mysql was given. +if test "${with_mysql+set}" = set; then + withval="$with_mysql" + +else + + +# Check whether --with-mysqlconfig-path or --without-mysqlconfig-path was given. +if test "${with_mysqlconfig_path+set}" = set; then + withval="$with_mysqlconfig_path" + mysql_config_path="$withval" +else + mysql_config_path="" +fi; + MYSQLCONF="" + if test "$mysql_config_path" != ""; then + if test -x "$mysql_config_path"; then + MYSQLCONF="$mysql_config_path" + echo "checking for mysql_config... $MYSQLCONF" + fi + fi + if test "$MYSQLCONF" = ""; then + # Extract the first word of "mysql_config", so it can be a program name with args. +set dummy mysql_config; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_path_MYSQLCONF+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + case $MYSQLCONF in + [\\/]* | ?:[\\/]*) + ac_cv_path_MYSQLCONF="$MYSQLCONF" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_MYSQLCONF="$as_dir/$ac_word$ac_exec_ext" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + + test -z "$ac_cv_path_MYSQLCONF" && ac_cv_path_MYSQLCONF="""" + ;; +esac +fi +MYSQLCONF=$ac_cv_path_MYSQLCONF + +if test -n "$MYSQLCONF"; then + echo "$as_me:$LINENO: result: $MYSQLCONF" >&5 +echo "${ECHO_T}$MYSQLCONF" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + + fi + if test "$MYSQLCONF" != ""; then + +cat >>confdefs.h <<_ACEOF +#define USE_MYSQL 1 +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define USE_RDB 1 +_ACEOF + + MYSQL=" mysql.c " + RDB=" rdb.c " + + + MYSQL_CFLAGS="`$MYSQLCONF --cflags`" + MYSQL_LIBS="`$MYSQLCONF --libs`" + CFLAGS="$CFLAGS $MYSQL_CFLAGS" + LDFLAGS="$LDFLAGS $MYSQL_LIBS" + DIS_MYSQL=" MySql: Yes" + fi + +fi; + + + + ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -3281,357 +3364,6 @@ fi done - -# Check whether --with-mysql or --without-mysql was given. -if test "${with_mysql+set}" = set; then - withval="$with_mysql" - -else - - - -# Check whether --with-mysqlclient-prefix or --without-mysqlclient-prefix was given. -if test "${with_mysqlclient_prefix+set}" = set; then - withval="$with_mysqlclient_prefix" - mysqlclient_prefix="$withval" -else - mysqlclient_prefix="" -fi; - - -# Check whether --with-mysqlclient-include or --without-mysqlclient-include was given. -if test "${with_mysqlclient_include+set}" = set; then - withval="$with_mysqlclient_include" - mysqlclient_include="$withval" -else - mysqlclient_include="" -fi; - - -# Check whether --with-mysqlclient-lib or --without-mysqlclient-lib was given. -if test "${with_mysqlclient_lib+set}" = set; then - withval="$with_mysqlclient_lib" - mysqlclient_lib="$withval" -else - mysqlclient_lib="" -fi; - - echo "$as_me:$LINENO: checking for mysqlclient " >&5 -echo $ECHO_N "checking for mysqlclient ... $ECHO_C" >&6 - MYSQLCLIENT_LDFLAGS="" - MYSQLCLIENT_CFLAGS="" - MYSQLCLIENT_LIBS="-lmysqlclient" - mysqlclient_fail="" - - for tryprefix in /usr /usr/local /usr/mysql /usr/local/mysql /usr/pkg $msqlclient_prefix; do - #testloop - for hloc in lib/mysql lib ; do - if test -e "$tryprefix/$hloc/libmysqlclient.so"; then - MYSQLCLIENT_LDFLAGS="-L$tryprefix/$hloc" - fi - done - - for iloc in include/mysql include; do - if test -e "$tryprefix/$iloc/mysql.h"; then - MYSQLCLIENT_CFLAGS="-I$tryprefix/$iloc" - fi - done - # testloop - done - - if test "x$mysqlclient_include" != "x" ; then - echo "checking for mysql includes... " - if test -d "$mysqlclient_include/mysql" ; then - MYSQLCLIENT_CFLAGS="-I$mysqlclient_include" - echo " found $MYSQLCLIENT_CFLAGS" - elif test -d "$mysqlclient_include/include/mysql" ; then - MYSQLCLIENT_CFLAGS="-I$mysqlclient_include/include" - echo " found $MYSQLCLIENT_CFLAGS" - elif test -d "$mysqlclient_include" ; then - MYSQLCLIENT_CFLAGS="-I$mysqlclient_include" - echo "found $MYSQLCLIENT_CFLAGS" - else - echo "not found! no include dir found in $mysqlclient_include" - fi - fi - - if test "x$mysqlclient_lib" != "x" ; then - echo "checking for mysql libx... " - if test -d "$mysqlclient_lib/lib/mysql" ; then - MYSQLCLIENT_LDFLAGS="-L$mysqlclient_lib/lib/mysql" - echo "found $MYSQLCLIENT_LDFLAGS" - elif test -d "$mysqlclient_lib/lin" ; then - MYSQLCLIENT_LDFLAGS="-L$mysqlclient_lib/lib" - echo "found $MYSQLCLIENT_LDFLAGS" - else - MYSQLCLIENT_LDFLAGS="-L$mysqlclient_lib" - echo "defaultd to $MYSQLCLIENT_LDFLAGS" - fi - fi - - ac_save_CFLAGS="$CFLAGS" - ac_save_LDFLAGS="$LDFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="-v $CFLAGS $MYSQLCLIENT_CFLAGS" - LDFLAGS="$LDFLAGS $MYSQLCLIENT_LDFLAGS" - LIBS="$LIBS $MYSQLCLIENT_LIBS" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - #include <mysql.h> - #include <mysql_version.h> - -int -main () -{ - - mysql_connect( 0, 0, 0, 0); - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - echo "$as_me:$LINENO: result: yes $MYSQLCLIENT_CFLAGS $MYSQLCLIENT_LDFLAGS" >&5 -echo "${ECHO_T}yes $MYSQLCLIENT_CFLAGS $MYSQLCLIENT_LDFLAGS" >&6 - CFLAGS="$ac_save_CFLAGS" - LDFLAGS="$ac_save_LDFLAGS" - LIBS="$ac_save_LIBS" - - -cat >>confdefs.h <<_ACEOF -#define USE_MYSQL 1 -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define USE_RDB 1 -_ACEOF - - if test "${ac_cv_header_mysql_mysql_h+set}" = set; then - echo "$as_me:$LINENO: checking for mysql/mysql.h" >&5 -echo $ECHO_N "checking for mysql/mysql.h... $ECHO_C" >&6 -if test "${ac_cv_header_mysql_mysql_h+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -fi -echo "$as_me:$LINENO: result: $ac_cv_header_mysql_mysql_h" >&5 -echo "${ECHO_T}$ac_cv_header_mysql_mysql_h" >&6 -else - # Is the header compilable? -echo "$as_me:$LINENO: checking mysql/mysql.h usability" >&5 -echo $ECHO_N "checking mysql/mysql.h usability... $ECHO_C" >&6 -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -#include <mysql/mysql.h> -_ACEOF -rm -f conftest.$ac_objext -if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; } && - { ac_try='test -s conftest.$ac_objext' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_header_compiler=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -ac_header_compiler=no -fi -rm -f conftest.err conftest.$ac_objext conftest.$ac_ext -echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 -echo "${ECHO_T}$ac_header_compiler" >&6 - -# Is the header present? -echo "$as_me:$LINENO: checking mysql/mysql.h presence" >&5 -echo $ECHO_N "checking mysql/mysql.h presence... $ECHO_C" >&6 -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <mysql/mysql.h> -_ACEOF -if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 - (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null; then - if test -s conftest.err; then - ac_cpp_err=$ac_c_preproc_warn_flag - ac_cpp_err=$ac_cpp_err$ac_c_werror_flag - else - ac_cpp_err= - fi -else - ac_cpp_err=yes -fi -if test -z "$ac_cpp_err"; then - ac_header_preproc=yes -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_header_preproc=no -fi -rm -f conftest.err conftest.$ac_ext -echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -echo "${ECHO_T}$ac_header_preproc" >&6 - -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { echo "$as_me:$LINENO: WARNING: mysql/mysql.h: accepted by the compiler, rejected by the preprocessor!" >&5 -echo "$as_me: WARNING: mysql/mysql.h: accepted by the compiler, rejected by the preprocessor!" >&2;} - { echo "$as_me:$LINENO: WARNING: mysql/mysql.h: proceeding with the compiler's result" >&5 -echo "$as_me: WARNING: mysql/mysql.h: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { echo "$as_me:$LINENO: WARNING: mysql/mysql.h: present but cannot be compiled" >&5 -echo "$as_me: WARNING: mysql/mysql.h: present but cannot be compiled" >&2;} - { echo "$as_me:$LINENO: WARNING: mysql/mysql.h: check for missing prerequisite headers?" >&5 -echo "$as_me: WARNING: mysql/mysql.h: check for missing prerequisite headers?" >&2;} - { echo "$as_me:$LINENO: WARNING: mysql/mysql.h: see the Autoconf documentation" >&5 -echo "$as_me: WARNING: mysql/mysql.h: see the Autoconf documentation" >&2;} - { echo "$as_me:$LINENO: WARNING: mysql/mysql.h: section \"Present But Cannot Be Compiled\"" >&5 -echo "$as_me: WARNING: mysql/mysql.h: section \"Present But Cannot Be Compiled\"" >&2;} - { echo "$as_me:$LINENO: WARNING: mysql/mysql.h: proceeding with the preprocessor's result" >&5 -echo "$as_me: WARNING: mysql/mysql.h: proceeding with the preprocessor's result" >&2;} - { echo "$as_me:$LINENO: WARNING: mysql/mysql.h: in the future, the compiler will take precedence" >&5 -echo "$as_me: WARNING: mysql/mysql.h: in the future, the compiler will take precedence" >&2;} - ( - cat <<\_ASBOX -## ------------------------------------------ ## -## Report this to the AC_PACKAGE_NAME lists. ## -## ------------------------------------------ ## -_ASBOX - ) | - sed "s/^/$as_me: WARNING: /" >&2 - ;; -esac -echo "$as_me:$LINENO: checking for mysql/mysql.h" >&5 -echo $ECHO_N "checking for mysql/mysql.h... $ECHO_C" >&6 -if test "${ac_cv_header_mysql_mysql_h+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_cv_header_mysql_mysql_h=$ac_header_preproc -fi -echo "$as_me:$LINENO: result: $ac_cv_header_mysql_mysql_h" >&5 -echo "${ECHO_T}$ac_cv_header_mysql_mysql_h" >&6 - -fi -if test $ac_cv_header_mysql_mysql_h = yes; then - -cat >>confdefs.h <<\_ACEOF -#define MYSQL_HEADER_PREFIX 1 -_ACEOF - -fi - - - MYSQL=" mysql.c " - RDB=" rdb.c " - - - x="1"; - - -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - - echo "no" - echo "can't compile a simple app with mysql_connnect in it. -bad." - mysqlclient_fail="yes" - -fi -rm -f conftest.err conftest.$ac_objext conftest.$ac_ext - - if test "x$mysqlclient_fail" != "x" ; then - echo - echo "***" - echo "*** mysqlclient test source had problems, check your config.log ." - echo "*** Also try one of the following switches :" - echo "*** --with-mysqlclient-prefix=PFX" - echo "*** --with-mysqlclient-include=DIR" - echo "*** --with-mysqlclient-lib=DIR" - echo "***" - CFLAGS="$ac_save_CFLAGS" - LDFLAGS="$ac_save_LDFLAGS" - LIBS="$ac_save_LIBS" - : - fi - - CFLAGS="$ac_save_CFLAGS" - LDFLAGS="$ac_save_LDFLAGS" - LIBS="$ac_save_LIBS" - - - - - -if test "$x" = "1"; then - ANOPELIBS="$ANOPELIBS$MYSQLCLIENT_LIBS " - CFLAGS="$CFLAGS $MYSQLCLIENT_CFLAGS " - LDFLAGS="$LDFLAGS $MYSQLCLIENT_LDFLAGS " - DIS_MYSQL=" MySql: Yes" -fi - -fi; - - - - if test "${ac_cv_header_sys_types_h+set}" = set; then echo "$as_me:$LINENO: checking for sys/types.h" >&5 echo $ECHO_N "checking for sys/types.h... $ECHO_C" >&6 @@ -4113,7 +3845,1890 @@ cat >>confdefs.h <<\_ACEOF _ACEOF -unreal_CHECK_TYPE_SIZES +echo "$as_me:$LINENO: checking for short" >&5 +echo $ECHO_N "checking for short... $ECHO_C" >&6 +if test "${ac_cv_type_short+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +if ((short *) 0) + return 0; +if (sizeof (short)) + return 0; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_type_short=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_type_short=no +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +fi +echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5 +echo "${ECHO_T}$ac_cv_type_short" >&6 + +echo "$as_me:$LINENO: checking size of short" >&5 +echo $ECHO_N "checking size of short... $ECHO_C" >&6 +if test "${ac_cv_sizeof_short+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test "$ac_cv_type_short" = yes; then + # The cast to unsigned long works around a bug in the HP C Compiler + # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects + # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. + # This bug is HP SR number 8606223364. + if test "$cross_compiling" = yes; then + # Depending upon the size, compute the lo and hi bounds. +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_lo=0 ac_mid=0 + while :; do + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_hi=$ac_mid; break +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_lo=`expr $ac_mid + 1` + if test $ac_lo -le $ac_mid; then + ac_lo= ac_hi= + break + fi + ac_mid=`expr 2 '*' $ac_mid + 1` +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext + done +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_hi=-1 ac_mid=-1 + while :; do + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_lo=$ac_mid; break +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_hi=`expr '(' $ac_mid ')' - 1` + if test $ac_mid -le $ac_hi; then + ac_lo= ac_hi= + break + fi + ac_mid=`expr 2 '*' $ac_mid` +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext + done +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_lo= ac_hi= +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +# Binary search between lo and hi bounds. +while test "x$ac_lo" != "x$ac_hi"; do + ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_hi=$ac_mid +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_lo=`expr '(' $ac_mid ')' + 1` +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +done +case $ac_lo in |
