diff --git a/ext/pdo_dblib/config.m4 b/ext/pdo_dblib/config.m4 index 0adf020c295..1b68a9913b3 100644 --- a/ext/pdo_dblib/config.m4 +++ b/ext/pdo_dblib/config.m4 @@ -4,14 +4,14 @@ PHP_ARG_WITH([pdo-dblib], [PDO: DBLIB-DB support. DIR is the FreeTDS home directory])]) if test "$PHP_PDO_DBLIB" != "no"; then - if test "$PHP_PDO_DBLIB" = "yes"; then + AS_VAR_IF([PHP_PDO_DBLIB], [yes], [ dnl FreeTDS must be on the default system include/library path. dnl Only perform a sanity check that this is really the case. PHP_CHECK_LIBRARY([sybdb], [dbsqlexec], [], [AC_MSG_FAILURE([Cannot find FreeTDS in known installation directories.])]) PHP_ADD_LIBRARY([sybdb],, [PDO_DBLIB_SHARED_LIBADD]) - elif test "$PHP_PDO_DBLIB" != "no"; then + ], [ if test -f $PHP_PDO_DBLIB/include/sybdb.h; then PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include @@ -32,7 +32,7 @@ if test "$PHP_PDO_DBLIB" != "no"; then PHP_ADD_LIBRARY_WITH_PATH([sybdb], [$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR], [PDO_DBLIB_SHARED_LIBADD]) - fi + ]) PHP_CHECK_PDO_INCLUDES