From: Manoj Kasichainula Date: Mon, 20 Dec 1999 03:09:50 +0000 (+0000) Subject: Eliminate the .h.stub files; AC_DEFINE can generate the necessary X-Git-Tag: 1.3.10~74 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8c0183b985680662ab032fc035e58c1077d2e4c1;p=apache Eliminate the .h.stub files; AC_DEFINE can generate the necessary #defines in the config header for us. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84329 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/acinclude.m4 b/acinclude.m4 index c999048f22..f45bc2ce1e 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -58,7 +58,8 @@ YES_IS_DEFINED #endif ], ac_cv_define_$1=yes, ac_cv_define_$1=no)) if test "$ac_cv_define_$1" = "yes" ; then - AC_DEFINE(HAVE_$1) + AC_DEFINE(HAVE_$1,, + [Define if the macro "$1" is defined on this system]) fi ]) @@ -75,7 +76,8 @@ AC_DEFUN(AC_TYPE_RLIM_T, [ ]) ]) if test "$ac_ac_type_rlim_t" = "no" ; then - AC_DEFINE(rlim_t, int) + AC_DEFINE(rlim_t, int, + [Define to 'int' if doesn't define it for us]) fi ]) diff --git a/configure.in b/configure.in index b57260a8ce..c392e2a0e7 100644 --- a/configure.in +++ b/configure.in @@ -100,7 +100,8 @@ if test "$ac_cv_func_select_arg1" != "int" \ -o "$ac_cv_func_select_arg234" != "fd_set *" \ -o "$ac_cv_func_select_arg5" != "struct timeval *" ; then - AC_DEFINE(SELECT_NEEDS_CAST) + AC_DEFINE(SELECT_NEEDS_CAST,, + [Define if arguments to select() aren't what we expect]) fi AM_PROG_LIBTOOL diff --git a/server/config.m4 b/server/config.m4 index c45474061b..6c146cff7f 100644 --- a/server/config.m4 +++ b/server/config.m4 @@ -1,5 +1,7 @@ dnl ## Check for libraries +AC_DEFUN(APACHE_DEFINE_HAVE_CRYPT, [ +]) AC_CHECK_LIB(nsl, gethostname, [ AC_ADD_LIBRARY(nsl) ], []) @@ -11,10 +13,14 @@ AC_CHECK_LIB(nsl, gethostbyaddr, [ AC_CHECK_LIB(crypt, crypt, [ AC_ADD_LIBRARY(crypt) - AC_DEFINE(HAVE_CRYPT)], []) - -AC_CHECK_LIB(c, crypt, [ - AC_DEFINE(HAVE_CRYPT)], []) + apache_have_crypt=1 +], [ + AC_CHECK_LIB(c, crypt, [ + apache_have_crypt=1], []) +]) +if test "$apache_have_crypt" = "1" ; then + AC_DEFINE(HAVE_CRYPT,,[Define if this platform has crypt()]) +fi dnl ## Check for header files @@ -37,7 +43,8 @@ AC_CACHE_CHECK([for tm_gmtoff in struct tm], ac_cv_struct_tm_gmtoff, ac_cv_struct_tm_gmtoff=yes, ac_cv_struct_tm_gmtoff=no)]) if test "$ac_cv_struct_tm_gmtoff" = "yes"; then - AC_DEFINE(HAVE_GMTOFF) + AC_DEFINE(HAVE_GMTOFF,, + [Define if struct tm has a tm_gmtoff member]) fi dnl ## Check for library functions diff --git a/server/mpm/config.m4 b/server/mpm/config.m4 index 10366965d6..3af2173aea 100644 --- a/server/mpm/config.m4 +++ b/server/mpm/config.m4 @@ -29,10 +29,12 @@ AC_DEFUN(APACHE_MPM_CHECK_SHMEM, [ AC_MSG_CHECKING(which shared memory mechanism to use) if test "$ac_cv_func_shmget" = "yes" ; then - AC_DEFINE(USE_SHMGET_SCOREBOARD) + AC_DEFINE(USE_SHMGET_SCOREBOARD,, + [Define if MPMs should use shmget to implement their shared memory]) AC_MSG_RESULT(shmget) elif test "$ac_cv_func_mmap" = "yes" ; then - AC_DEFINE(USE_MMAP_SCOREBOARD) + AC_DEFINE(USE_MMAP_SCOREBOARD,, + [Define if MPMs should use mmap to implement their shared memory]) AC_MSG_RESULT(mmap) else AC_MSG_ERROR(No known shared memory system) @@ -55,5 +57,6 @@ dnl platform. This will cover a couple of them, anyway ]) dnl User threads libraries need pthread.h included everywhere - AC_DEFINE(PTHREAD_EVERYWHERE) + AC_DEFINE(PTHREAD_EVERYWHERE,, + [Define if all code should have #include ]) ])