diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 75 |
1 files changed, 46 insertions, 29 deletions
diff --git a/configure.ac b/configure.ac index 2f433939dc..5c1312f24a 100644 --- a/configure.ac +++ b/configure.ac @@ -272,6 +272,14 @@ AS_HELP_STRING([], [ARG can be also prefix for libpcre library and hea GIT_CONF_SUBST([LIBPCREDIR]) fi) # +# Define HAVE_ALLOCA_H if you have working alloca(3) defined in that header. +AC_FUNC_ALLOCA +case $ac_cv_working_alloca_h in + yes) HAVE_ALLOCA_H=YesPlease;; + *) HAVE_ALLOCA_H='';; +esac +GIT_CONF_SUBST([HAVE_ALLOCA_H]) +# # Define NO_CURL if you do not have curl installed. git-http-pull and # git-http-push are not built, and you cannot use http:// and https:// # transports. @@ -738,6 +746,14 @@ case $ac_cv_type_socklen_t in esac GIT_CONF_SUBST([SOCKLEN_T]) +# +# Define NO_STRUCT_ITIMERVAL if you don't have struct itimerval. +AC_CHECK_TYPES([struct itimerval], +[NO_STRUCT_ITIMERVAL=], +[NO_STRUCT_ITIMERVAL=UnfortunatelyYes], +[#include <sys/time.h>]) +GIT_CONF_SUBST([NO_STRUCT_ITIMERVAL]) +# # Define NO_D_INO_IN_DIRENT if you don't have d_ino in your struct dirent. AC_CHECK_MEMBER(struct dirent.d_ino, [NO_D_INO_IN_DIRENT=], @@ -857,6 +873,29 @@ else SNPRINTF_RETURNS_BOGUS= fi GIT_CONF_SUBST([SNPRINTF_RETURNS_BOGUS]) +# +# Define NEEDS_MODE_TRANSLATION if your OS strays from the typical file type +# bits in mode values. +AC_CACHE_CHECK([whether the platform uses typical file type bits], + [ac_cv_sane_mode_bits], [ +AC_EGREP_CPP(yippeeyeswehaveit, + AC_LANG_PROGRAM([AC_INCLUDES_DEFAULT], +[#if S_IFMT == 0170000 && \ + S_IFREG == 0100000 && S_IFDIR == 0040000 && S_IFLNK == 0120000 && \ + S_IFBLK == 0060000 && S_IFCHR == 0020000 && \ + S_IFIFO == 0010000 && S_IFSOCK == 0140000 +yippeeyeswehaveit +#endif +]), + [ac_cv_sane_mode_bits=yes], + [ac_cv_sane_mode_bits=no]) +]) +if test $ac_cv_sane_mode_bits = yes; then + NEEDS_MODE_TRANSLATION= +else + NEEDS_MODE_TRANSLATION=UnfortunatelyYes +fi +GIT_CONF_SUBST([NEEDS_MODE_TRANSLATION]) ## Checks for library functions. @@ -890,45 +929,23 @@ GIT_CONF_SUBST([HAVE_STRINGS_H]) # and libcharset does CHARSET_LIB= AC_CHECK_LIB([iconv], [locale_charset], - [], + [CHARSET_LIB=-liconv], [AC_CHECK_LIB([charset], [locale_charset], [CHARSET_LIB=-lcharset])]) GIT_CONF_SUBST([CHARSET_LIB]) # +# Define NO_SETITIMER if you don't have setitimer. +GIT_CHECK_FUNC(setitimer, +[NO_SETITIMER=], +[NO_SETITIMER=YesPlease]) +GIT_CONF_SUBST([NO_SETITIMER]) +# # Define NO_STRCASESTR if you don't have strcasestr. GIT_CHECK_FUNC(strcasestr, [NO_STRCASESTR=], [NO_STRCASESTR=YesPlease]) GIT_CONF_SUBST([NO_STRCASESTR]) # -# Define NO_FNMATCH if you don't have fnmatch -GIT_CHECK_FUNC(fnmatch, -[NO_FNMATCH=], -[NO_FNMATCH=YesPlease]) -GIT_CONF_SUBST([NO_FNMATCH]) -# -# Define NO_FNMATCH_CASEFOLD if your fnmatch function doesn't have the -# FNM_CASEFOLD GNU extension. -AC_CACHE_CHECK([whether the fnmatch function supports the FNMATCH_CASEFOLD GNU extension], - [ac_cv_c_excellent_fnmatch], [ -AC_EGREP_CPP(yippeeyeswehaveit, - AC_LANG_PROGRAM([ -#include <fnmatch.h> -], -[#ifdef FNM_CASEFOLD -yippeeyeswehaveit -#endif -]), - [ac_cv_c_excellent_fnmatch=yes], - [ac_cv_c_excellent_fnmatch=no]) -]) -if test $ac_cv_c_excellent_fnmatch = yes; then - NO_FNMATCH_CASEFOLD= -else - NO_FNMATCH_CASEFOLD=YesPlease -fi -GIT_CONF_SUBST([NO_FNMATCH_CASEFOLD]) -# # Define NO_MEMMEM if you don't have memmem. GIT_CHECK_FUNC(memmem, [NO_MEMMEM=], |