In this case, the ircg extension refers to thttpd-specific symbols
which causes the build of the cli sapi module to fail.
ZEND_DIR = $(srcdir)/Zend
-SUBDIRS = Zend main ext sapi $(TSRM_DIR) $(REGEX_DIR) sapi/cli . $(PEAR_DIR)
+SUBDIRS = Zend main ext sapi $(TSRM_DIR) $(REGEX_DIR) $(CLI_DIR) . $(PEAR_DIR)
LTLIBRARY_NAME = libphp4.la
LTLIBRARY_SOURCES = stub.c
sinclude(dynlib.m4)
+dnl
+dnl Disable building CLI
+dnl
+AC_DEFUN(PHP_DISABLE_CLI,[
+ disable_cli=1
+])
+
dnl
dnl Separator into the configure --help display.
dnl
PHP_OS=`uname`
AC_DEFINE_UNQUOTED(PHP_OS,"$PHP_OS",[uname output])
+if test "$disable_cgi" = "1"; then
+ CLI_DIR=
+else
+ CLI_DIR=sapi/cli
+fi
+
+PHP_SUBST(CLI_DIR)
PHP_SUBST(EXT_SUBDIRS)
PHP_SUBST(EXT_STATIC)