summaryrefslogtreecommitdiff
path: root/acinclude.m4
diff options
context:
space:
mode:
authorJani Taskinen <jani@php.net>2009-05-09 20:26:51 +0000
committerJani Taskinen <jani@php.net>2009-05-09 20:26:51 +0000
commit558f3861ecf4e8b9f33c020553eac23f5381de0a (patch)
treeb27b6d000d836e7eeca70877ae302f8074b5e994 /acinclude.m4
parentcc33f375a6aaa3278e5a36d2b2356d0aa2579225 (diff)
downloadphp-git-558f3861ecf4e8b9f33c020553eac23f5381de0a.tar.gz
MFH:- Fixed bug #47468 (enable cli|cgi-only extensions for embed sapi)
Diffstat (limited to 'acinclude.m4')
-rw-r--r--acinclude.m417
1 files changed, 10 insertions, 7 deletions
diff --git a/acinclude.m4 b/acinclude.m4
index 39e71e6ca4..486d28d0b4 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -920,7 +920,7 @@ AC_DEFUN([PHP_GEN_BUILD_DIRS],[
])
dnl
-dnl PHP_NEW_EXTENSION(extname, sources [, shared [,sapi_class[, extra-cflags[, cxx[, zend_ext]]]]])
+dnl PHP_NEW_EXTENSION(extname, sources [, shared [, sapi_class [, extra-cflags [, cxx [, zend_ext]]]]])
dnl
dnl Includes an extension in the build.
dnl
@@ -968,12 +968,15 @@ dnl ---------------------------------------------- Shared module
if test "$3" != "shared" && test "$3" != "yes" && test "$4" = "cli"; then
dnl ---------------------------------------------- CLI static module
[PHP_]translit($1,a-z_-,A-Z__)[_SHARED]=no
- if test "$PHP_SAPI" = "cgi"; then
- PHP_ADD_SOURCES(PHP_EXT_DIR($1),$2,$ac_extra,)
- EXT_STATIC="$EXT_STATIC $1"
- else
- PHP_ADD_SOURCES(PHP_EXT_DIR($1),$2,$ac_extra,cli)
- fi
+ case "$PHP_SAPI" in
+ cgi|embed[)]
+ PHP_ADD_SOURCES(PHP_EXT_DIR($1),$2,$ac_extra,)
+ EXT_STATIC="$EXT_STATIC $1"
+ ;;
+ *[)]
+ PHP_ADD_SOURCES(PHP_EXT_DIR($1),$2,$ac_extra,cli)
+ ;;
+ esac
EXT_CLI_STATIC="$EXT_CLI_STATIC $1"
fi
PHP_ADD_BUILD_DIR($ext_builddir)