dnl
AC_DEFUN([PHP_CHECK_PDO_INCLUDES],[
AC_CACHE_CHECK([for PDO includes], pdo_cv_inc_path, [
- AC_MSG_CHECKING([for PDO includes])
if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
pdo_cv_inc_path=$abs_srcdir/ext
elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
PHP_ADD_INCLUDE($PDO_FREETDS_INCLUDE_DIR)
PHP_ADD_LIBRARY_WITH_PATH(sybdb, $PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR, PDO_DBLIB_SHARED_LIBADD)
- ifdef([PHP_CHECK_PDO_INCLUDES],
- [
- PHP_CHECK_PDO_INCLUDES
- ],[
- AC_MSG_CHECKING([for PDO includes])
- if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$phpincludedir/ext
- else
- AC_MSG_ERROR([Cannot find php_pdo_driver.h.])
- fi
- AC_MSG_RESULT($pdo_cv_inc_path)
- ])
+ PHP_CHECK_PDO_INCLUDES
PDO_DBLIB_DEFS="-DPDO_DBLIB_FLAVOUR=\\\"freetds\\\""
PHP_NEW_EXTENSION(pdo_dblib, pdo_dblib.c dblib_driver.c dblib_stmt.c, $ext_shared,,-I$pdo_cv_inc_path $PDO_DBLIB_DEFS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1)
])
fi
- ifdef([PHP_CHECK_PDO_INCLUDES],
- [
- PHP_CHECK_PDO_INCLUDES
- ],[
- AC_MSG_CHECKING([for PDO includes])
- if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$phpincludedir/ext
- else
- AC_MSG_ERROR([Cannot find php_pdo_driver.h.])
- fi
- AC_MSG_RESULT($pdo_cv_inc_path)
- ])
+ PHP_CHECK_PDO_INCLUDES
if test -n "$PDO_MYSQL_CONFIG"; then
PDO_MYSQL_SOCKET=`$PDO_MYSQL_CONFIG --socket`
-L$PDO_OCI_LIB_DIR $PDO_OCI_SHARED_LIBADD
])
- ifdef([PHP_CHECK_PDO_INCLUDES],
- [
- PHP_CHECK_PDO_INCLUDES
- ],[
- AC_MSG_CHECKING([for PDO includes])
- if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$phpincludedir/ext
- else
- AC_MSG_ERROR([Cannot find php_pdo_driver.h.])
- fi
- AC_MSG_RESULT($pdo_cv_inc_path)
- ])
+ PHP_CHECK_PDO_INCLUDES
PHP_NEW_EXTENSION(pdo_oci, pdo_oci.c oci_driver.c oci_statement.c, $ext_shared,,-I$pdo_cv_inc_path)
AC_MSG_ERROR([PDO is not enabled! Add --enable-pdo to your configure line.])
fi
- ifdef([PHP_CHECK_PDO_INCLUDES],
- [
- PHP_CHECK_PDO_INCLUDES
- ],[
- AC_MSG_CHECKING([for PDO includes])
- if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$phpincludedir/ext
- else
- AC_MSG_ERROR([Cannot find php_pdo_driver.h.])
- fi
- AC_MSG_RESULT($pdo_cv_inc_path)
- ])
+ PHP_CHECK_PDO_INCLUDES
AC_MSG_CHECKING([for selected PDO ODBC flavour])
PHP_ADD_INCLUDE($PGSQL_INCLUDE)
- ifdef([PHP_CHECK_PDO_INCLUDES],
- [
- PHP_CHECK_PDO_INCLUDES
- ],[
- AC_MSG_CHECKING([for PDO includes])
- if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$phpincludedir/ext
- else
- AC_MSG_ERROR([Cannot find php_pdo_driver.h.])
- fi
- AC_MSG_RESULT($pdo_cv_inc_path)
- ])
+ PHP_CHECK_PDO_INCLUDES
PHP_NEW_EXTENSION(pdo_pgsql, pdo_pgsql.c pgsql_driver.c pgsql_statement.c, $ext_shared,,-I$pdo_cv_inc_path)
ifdef([PHP_ADD_EXTENSION_DEP],
AC_MSG_ERROR([PDO is not enabled! Add --enable-pdo to your configure line.])
fi
- ifdef([PHP_CHECK_PDO_INCLUDES],
- [
- PHP_CHECK_PDO_INCLUDES
- ],[
- AC_MSG_CHECKING([for PDO includes])
- if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$abs_srcdir/ext
- elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
- pdo_cv_inc_path=$phpincludedir/ext
- else
- AC_MSG_ERROR([Cannot find php_pdo_driver.h.])
- fi
- AC_MSG_RESULT($pdo_cv_inc_path)
- ])
+ PHP_CHECK_PDO_INCLUDES
PKG_CHECK_MODULES([SQLITE], [sqlite3 > 3.7.4])