]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Separate enablement of AP_DEBUG code from enablement of code
authorJeff Trawick <trawick@apache.org>
Sun, 13 May 2001 12:21:25 +0000 (12:21 +0000)
committerJeff Trawick <trawick@apache.org>
Sun, 13 May 2001 12:21:25 +0000 (12:21 +0000)
which depends on the compiler supporting designated initializers.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89103 13f79535-47bb-0310-9956-ffa450edef68

configure.in
include/http_config.h

index ff83aafe3e8af53562d81235d80f8673cd493057..e16e21d379bf652445e70ce9fc3a766a7fc21369 100644 (file)
@@ -190,6 +190,9 @@ AC_HEADER_SYS_WAIT
 dnl ## Check for typedefs, structures, and compiler characteristics.
 
 AC_C_CONST
+if test "$ac_cv_prog_gcc" = "yes"; then
+  APR_ADDTO(CPPFLAGS,-DAP_HAVE_DESIGNATED_INITIALIZER)
+fi
 
 dnl ## Check for library functions
 
@@ -209,9 +212,6 @@ AC_ARG_WITH(port,[  --with-port=PORT        Port on which to listen (default is
 
 AC_ARG_ENABLE(maintainer-mode,[  --enable-maintainer-mode  Turn on debugging and compile time warnings],
 [
-  if test "$ac_cv_prog_gcc" = "yes"; then
-    APR_ADDTO(CPPFLAGS,-DAP_DEBUG_HAVE_GCC)
-  fi
   APR_ADDTO(CPPFLAGS, -DAP_DEBUG)
 ])dnl
 
index 7706ba51d7c987f7684c8b532299628d0c5953ad..b514743187ecf96f641e67654f386fb4bb914d5d 100644 (file)
@@ -120,7 +120,7 @@ enum cmd_how {
 
 typedef struct cmd_parms_struct cmd_parms;
 
-#ifdef AP_DEBUG_HAVE_GCC
+#ifdef AP_HAVE_DESIGNATED_INITIALIZER
 
 typedef union {
     const char *(*no_args) (cmd_parms *parms, void *mconfig);
@@ -162,7 +162,7 @@ typedef union {
 # define AP_INIT_FLAG(directive, func, mconfig, where, help) \
     { directive, { .flag=func }, mconfig, where, FLAG, help }
 
-#else /* AP_DEBUG_HAVE_GCC */
+#else /* AP_HAVE_DESIGNATED_INITIALIZER */
 
 typedef const char *(*cmd_func) ();
 
@@ -194,7 +194,7 @@ typedef const char *(*cmd_func) ();
 # define AP_INIT_FLAG(directive, func, mconfig, where, help) \
     { directive, func, mconfig, where, FLAG, help }
 
-#endif /* AP_DEBUG_HAVE_GCC */
+#endif /* AP_HAVE_DESIGNATED_INITIALIZER */
 
 typedef struct command_struct command_rec; 
 /**