diff options
Diffstat (limited to 'maildir')
| -rw-r--r-- | maildir/configure.ac | 38 | ||||
| -rw-r--r-- | maildir/maildircreate.c | 7 | ||||
| -rw-r--r-- | maildir/maildirinfo.c | 6 | ||||
| -rw-r--r-- | maildir/maildirnewshared2.c | 12 | ||||
| -rw-r--r-- | maildir/testmaildiraclt.c | 7 |
5 files changed, 25 insertions, 45 deletions
diff --git a/maildir/configure.ac b/maildir/configure.ac index 5c2a64c..9ab0cdb 100644 --- a/maildir/configure.ac +++ b/maildir/configure.ac @@ -3,14 +3,14 @@ dnl dnl Copyright 1998 - 2001 Double Precision, Inc. See COPYING for dnl distribution information. -AC_INIT(maildir, 0.11, [courier-maildrop@lists.sourceforge.net]) +AC_INIT([maildir],[0.11],[courier-maildrop@lists.sourceforge.net]) >confdefs.h # Kill PACKAGE_ macros AC_CONFIG_SRCDIR(maildirquota.c) AC_CONFIG_AUX_DIR(../..) LPATH="$PATH:/usr/local/bin" -AC_CANONICAL_SYSTEM +AC_CANONICAL_TARGET AM_INIT_AUTOMAKE([foreign no-define]) AC_CONFIG_HEADERS(config.h) @@ -18,11 +18,13 @@ dnl Checks for programs. AC_PROG_AWK AC_USE_SYSTEM_EXTENSIONS AC_PROG_CC -AC_PROG_CC_C99 AC_PROG_INSTALL AC_PROG_LN_S -AC_LIBTOOL_DLOPEN -AM_PROG_LIBTOOL +_LT_SET_OPTION([LT_INIT],[dlopen]) +m4_warn([obsolete],[AC_LIBTOOL_DLOPEN: Remove this warning and the call to _LT_SET_OPTION when you +put the 'dlopen' option into LT_INIT's first parameter.]) + +LT_INIT AC_PROG_CXX @@ -45,8 +47,15 @@ dnl Checks for libraries. dnl Checks for header files. AC_HEADER_DIRENT -AC_HEADER_STDC -AC_HEADER_TIME + +AC_CHECK_HEADERS_ONCE([sys/time.h]) +# Obsolete code to be removed. +if test $ac_cv_header_sys_time_h = yes; then + AC_DEFINE([TIME_WITH_SYS_TIME],[1],[Define to 1 if you can safely include both <sys/time.h> + and <time.h>. This macro is obsolete.]) +fi +# End of obsolete code. + AC_CHECK_HEADERS(sys/stat.h sys/wait.h fcntl.h unistd.h sysexits.h utime.h) AC_CHECK_PROG(PCRE2, pcre2-config, yes, no) @@ -62,9 +71,9 @@ AC_SUBST(PCRE_CFLAGS) AC_HEADER_SYS_WAIT -AC_LANG_CPLUSPLUS +AC_LANG([C++]) AC_CHECK_HEADERS(vector vector.h) -AC_LANG_C +AC_LANG([C]) dnl Checks for typedefs, structures, and compiler characteristics. AC_C_CONST @@ -83,15 +92,15 @@ AC_CHECK_FUNCS(inotify_init inotify_init1) AC_CACHE_CHECK([for missing gethostname prototype],maildir_cv_SYS_GETHOSTNAME, -AC_TRY_COMPILE([ +AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #if HAVE_UNISTD_H #include <unistd.h> #endif extern int gethostname(int,int); -],[ -],maildir_cv_SYS_GETHOSTNAME=yes,maildir_cv_SYS_GETHOSTNAME=no -) +]], [[ +]])],[maildir_cv_SYS_GETHOSTNAME=yes],[maildir_cv_SYS_GETHOSTNAME=no +]) ) @@ -153,4 +162,5 @@ else [ Maildir target separator ]) fi -AC_OUTPUT(Makefile sharedindexinstall sharedindexsplit) +AC_CONFIG_FILES([Makefile sharedindexinstall sharedindexsplit]) +AC_OUTPUT diff --git a/maildir/maildircreate.c b/maildir/maildircreate.c index b0c8e01..cb334ed 100644 --- a/maildir/maildircreate.c +++ b/maildir/maildircreate.c @@ -10,16 +10,11 @@ #include <sys/stat.h> #endif -#if TIME_WITH_SYS_TIME -#include <sys/time.h> #include <time.h> -#else #if HAVE_SYS_TIME_H #include <sys/time.h> -#else -#include <time.h> -#endif #endif + #if HAVE_SYS_STAT_H #include <sys/stat.h> #endif diff --git a/maildir/maildirinfo.c b/maildir/maildirinfo.c index 5db7f89..610b6e0 100644 --- a/maildir/maildirinfo.c +++ b/maildir/maildirinfo.c @@ -18,15 +18,9 @@ #if HAVE_UTIME_H #include <utime.h> #endif -#if TIME_WITH_SYS_TIME -#include <sys/time.h> #include <time.h> -#else #if HAVE_SYS_TIME_H #include <sys/time.h> -#else -#include <time.h> -#endif #endif #include <sys/types.h> diff --git a/maildir/maildirnewshared2.c b/maildir/maildirnewshared2.c index 55c5c0e..801eac3 100644 --- a/maildir/maildirnewshared2.c +++ b/maildir/maildirnewshared2.c @@ -18,15 +18,9 @@ #if HAVE_UTIME_H #include <utime.h> #endif -#if TIME_WITH_SYS_TIME -#include <sys/time.h> #include <time.h> -#else #if HAVE_SYS_TIME_H #include <sys/time.h> -#else -#include <time.h> -#endif #endif #include <sys/types.h> @@ -229,9 +223,3 @@ static struct maildir_shindex_cache *do_shared_cache_read(const char *indexfile, return c; } - - - - - - diff --git a/maildir/testmaildiraclt.c b/maildir/testmaildiraclt.c index 19fb14f..c19b2f5 100644 --- a/maildir/testmaildiraclt.c +++ b/maildir/testmaildiraclt.c @@ -17,18 +17,11 @@ #if HAVE_UTIME_H #include <utime.h> #endif -#if TIME_WITH_SYS_TIME -#include <sys/time.h> #include <time.h> -#else #if HAVE_SYS_TIME_H #include <sys/time.h> -#else -#include <time.h> -#endif #endif - #define CHK(x) if (!(x)) { printf("%s(%d): sanity check failed.\n", \ __FILE__, __LINE__); exit(1);} |
