summaryrefslogtreecommitdiff
path: root/sapi
diff options
context:
space:
mode:
authorSascha Schumann <sas@php.net>2000-06-08 06:14:58 +0000
committerSascha Schumann <sas@php.net>2000-06-08 06:14:58 +0000
commite49ad341bd898b31bdb03ae7f032f476297418a1 (patch)
treec0f303487eb6986fd4a11d10ab9dae690b737560 /sapi
parentb4e48b952ef8c76f8652f2ca7935a6d852cea306 (diff)
downloadphp-git-e49ad341bd898b31bdb03ae7f032f476297418a1.tar.gz
Wipe out acconfig.h.in and rewrite some checks to use PHP_ARG_ENABLE.
Diffstat (limited to 'sapi')
-rw-r--r--sapi/apache/config.m432
-rw-r--r--sapi/cgi/config.m444
-rw-r--r--sapi/isapi/config.m42
3 files changed, 32 insertions, 46 deletions
diff --git a/sapi/apache/config.m4 b/sapi/apache/config.m4
index e6530b5d3a..8b838f46b4 100644
--- a/sapi/apache/config.m4
+++ b/sapi/apache/config.m4
@@ -43,8 +43,8 @@ AC_ARG_WITH(apxs,
PHP_APXS_BROKEN=yes
fi
STRONGHOLD=
- AC_DEFINE(HAVE_AP_CONFIG_H)
- AC_DEFINE(HAVE_AP_COMPAT_H)
+ AC_DEFINE(HAVE_AP_CONFIG_H,1,[ ])
+ AC_DEFINE(HAVE_AP_COMPAT_H,1,[ ])
AC_MSG_RESULT(yes)
],[
AC_MSG_RESULT(no)
@@ -74,7 +74,7 @@ AC_ARG_WITH(apache,
AC_MSG_RESULT(yes - Apache 1.2.x)
STRONGHOLD=
if test -f $withval/src/ap_config.h; then
- AC_DEFINE(HAVE_AP_CONFIG_H)
+ AC_DEFINE(HAVE_AP_CONFIG_H,1,[ ])
fi
# For Apache 2.0.x
elif test -f $withval/src/include/httpd.h &&
@@ -91,16 +91,16 @@ AC_ARG_WITH(apache,
AC_MSG_RESULT(yes - Apache 2.0.X)
STRONGHOLD=
if test -f $withval/src/include/ap_config.h; then
- AC_DEFINE(HAVE_AP_CONFIG_H)
+ AC_DEFINE(HAVE_AP_CONFIG_H,1,[ ])
fi
if test -f $withval/src/include/ap_compat.h; then
- AC_DEFINE(HAVE_AP_COMPAT_H)
+ AC_DEFINE(HAVE_AP_COMPAT_H,1,[ ])
if test ! -f $withval/src/include/ap_config_auto.h; then
AC_MSG_ERROR(Please run Apache\'s configure or src/Configure program once and try again)
fi
else
if test -f $withval/src/include/compat.h; then
- AC_DEFINE(HAVE_OLD_COMPAT_H)
+ AC_DEFINE(HAVE_OLD_COMPAT_H,1,[ ])
fi
fi
# For Apache 1.3.x
@@ -117,16 +117,16 @@ AC_ARG_WITH(apache,
AC_MSG_RESULT(yes - Apache 1.3.x)
STRONGHOLD=
if test -f $withval/src/include/ap_config.h; then
- AC_DEFINE(HAVE_AP_CONFIG_H)
+ AC_DEFINE(HAVE_AP_CONFIG_H,1,[ ])
fi
if test -f $withval/src/include/ap_compat.h; then
- AC_DEFINE(HAVE_AP_COMPAT_H)
+ AC_DEFINE(HAVE_AP_COMPAT_H,1,[ ])
if test ! -f $withval/src/include/ap_config_auto.h; then
AC_MSG_ERROR(Please run Apache\'s configure or src/Configure program once and try again)
fi
else
if test -f $withval/src/include/compat.h; then
- AC_DEFINE(HAVE_OLD_COMPAT_H)
+ AC_DEFINE(HAVE_OLD_COMPAT_H,1,[ ])
fi
fi
# Also for Apache 1.3.x
@@ -143,16 +143,16 @@ AC_ARG_WITH(apache,
AC_MSG_RESULT(yes - Apache 1.3.x)
STRONGHOLD=
if test -f $withval/src/include/ap_config.h; then
- AC_DEFINE(HAVE_AP_CONFIG_H)
+ AC_DEFINE(HAVE_AP_CONFIG_H,1,[ ])
fi
if test -f $withval/src/include/ap_compat.h; then
- AC_DEFINE(HAVE_AP_COMPAT_H)
+ AC_DEFINE(HAVE_AP_COMPAT_H,1,[ ])
if test ! -f $withval/src/include/ap_config_auto.h; then
AC_MSG_ERROR(Please run Apache\'s configure or src/Configure program once and try again)
fi
else
if test -f $withval/src/include/compat.h; then
- AC_DEFINE(HAVE_OLD_COMPAT_H)
+ AC_DEFINE(HAVE_OLD_COMPAT_H,1,[ ])
fi
fi
# For StrongHold 2.2
@@ -165,16 +165,16 @@ AC_ARG_WITH(apache,
STRONGHOLD=-DSTRONGHOLD=1
AC_MSG_RESULT(yes - StrongHold)
if test -f $withval/apache/ap_config.h; then
- AC_DEFINE(HAVE_AP_CONFIG_H)
+ AC_DEFINE(HAVE_AP_CONFIG_H,1,[ ])
fi
if test -f $withval/src/ap_compat.h; then
- AC_DEFINE(HAVE_AP_COMPAT_H)
+ AC_DEFINE(HAVE_AP_COMPAT_H,1,[ ])
if test ! -f $withval/src/include/ap_config_auto.h; then
AC_MSG_ERROR(Please run Apache\'s configure or src/Configure program once and try again)
fi
else
if test -f $withval/src/compat.h; then
- AC_DEFINE(HAVE_OLD_COMPAT_H)
+ AC_DEFINE(HAVE_OLD_COMPAT_H,1,[ ])
fi
fi
else
@@ -208,7 +208,7 @@ AC_ARG_WITH(mod_charset,
[ --with-mod_charset Enable transfer tables for mod_charset (Rus Apache).],
[
AC_MSG_RESULT(yes)
- AC_DEFINE(USE_TRANSFER_TABLES)
+ AC_DEFINE(USE_TRANSFER_TABLES,1,[ ])
],[
AC_MSG_RESULT(no)
])
diff --git a/sapi/cgi/config.m4 b/sapi/cgi/config.m4
index 09d4aa9362..c0e7fab3cb 100644
--- a/sapi/cgi/config.m4
+++ b/sapi/cgi/config.m4
@@ -1,48 +1,34 @@
if test "$PHP_SAPI" = "cgi"; then
-AC_MSG_CHECKING(whether to force Apache CGI redirect)
-AC_ARG_ENABLE(force-cgi-redirect,
+
+ PHP_ARG_ENABLE(force-cgi-redirect,whether to force Apache CGI redirect,
[ --enable-force-cgi-redirect
Enable the security check for internal server
redirects. You should use this if you are
- running the CGI version with Apache. ],
-[
- if test "$enableval" = "yes"; then
- AC_DEFINE(FORCE_CGI_REDIRECT, 1)
- AC_MSG_RESULT(yes)
+ running the CGI version with Apache. ])
+
+ if test "$PHP_FORCE_CGI_REDIRECT" = "yes"; then
+ AC_DEFINE(FORCE_CGI_REDIRECT, 1, [ ])
REDIRECT=1
else
- AC_DEFINE(FORCE_CGI_REDIRECT, 0)
- AC_MSG_RESULT(no)
+ AC_DEFINE(FORCE_CGI_REDIRECT, 0, [ ])
REDIRECT=0
fi
-],[
- AC_DEFINE(FORCE_CGI_REDIRECT, 0)
- AC_MSG_RESULT(no)
- REDIRECT=0
-])
-AC_MSG_CHECKING(whether to discard path_info + path_translated)
-AC_ARG_ENABLE(discard_path,
+ PHP_ARG_ENABLE(discard-path,whether to discard path_info + path_translated,
[ --enable-discard-path If this is enabled, the PHP CGI binary
can safely be placed outside of the
web tree and people will not be able
- to circumvent .htaccess security. ],
-[
- if test "$enableval" = "yes"; then
- AC_DEFINE(DISCARD_PATH, 1)
- AC_MSG_RESULT(yes)
+ to circumvent .htaccess security. ])
+
+ if test "$PHP_DISCARD_PATH" = "yes"; then
+ AC_DEFINE(DISCARD_PATH, 1, [ ])
DISCARD_PATH=1
else
- AC_DEFINE(DISCARD_PATH, 0)
- AC_MSG_RESULT(no)
+ AC_DEFINE(DISCARD_PATH, 0, [ ])
DISCARD_PATH=0
fi
-],[
- AC_DEFINE(DISCARD_PATH, 0)
- AC_MSG_RESULT(no)
- DISCARD_PATH=0
-])
+
fi
if test "$PHP_SAPI" = "cgi" ; then
@@ -66,7 +52,7 @@ AC_ARG_WITH(fhttpd,
FHTTPD_TARGET=$withval/
PHP_BUILD_STATIC
PHP_SAPI=cgi
- AC_DEFINE(FHTTPD)
+ AC_DEFINE(FHTTPD,1,[ ])
AC_MSG_RESULT(yes - fhttpd 0.3.x)
else
AC_MSG_RESULT(no)
diff --git a/sapi/isapi/config.m4 b/sapi/isapi/config.m4
index b58eae2af9..116881d003 100644
--- a/sapi/isapi/config.m4
+++ b/sapi/isapi/config.m4
@@ -12,7 +12,7 @@ AC_ARG_WITH(zeus,
fi
test -f "$ZEUSPATH/web/include/httpext.h" || AC_MSG_ERROR(Unable to find httpext.h in $ZEUSPATH/web/include)
PHP_BUILD_THREAD_SAFE
- AC_DEFINE(WITH_ZEUS)
+ AC_DEFINE(WITH_ZEUS,1,[ ])
AC_ADD_INCLUDE($ZEUSPATH/web/include)
PHP_SAPI=isapi
PHP_BUILD_SHARED