From 5748b7f2c8a8e8e6d12b3e2531df5c0261fd8f3b Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Thu, 28 Jul 2022 12:09:04 +0100 Subject: [PATCH] patch 9.0.0098: missing include file in timer_create configure check Problem: missing include file in timer_create configure check. Solution: Inlucde stdlib.h. --- src/auto/configure | 15 ++++++++++++--- src/configure.ac | 16 ++++++++++++---- src/version.c | 2 ++ 3 files changed, 26 insertions(+), 7 deletions(-) diff --git a/src/auto/configure b/src/auto/configure index da57bd08a..dc9ee6e77 100755 --- a/src/auto/configure +++ b/src/auto/configure @@ -13042,7 +13042,8 @@ $as_echo_n "checking for timer_create... " >&6; } if ${vim_cv_timer_create+:} false; then : $as_echo_n "(cached) " >&6 else - save_LIBS="$LIBS" + +save_LIBS="$LIBS" LIBS="$LIBS -lrt" if test "$cross_compiling" = yes; then : as_fn_error $? "cross-compiling: please set 'vim_cv_timer_create'" "$LINENO" 5 @@ -13051,8 +13052,12 @@ else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include +#if STDC_HEADERS +# include +# include +#endif +#include +#include static void set_flag(union sigval sv) {} int @@ -13086,6 +13091,10 @@ else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#if STDC_HEADERS +# include +# include +#endif #include #include static void set_flag(union sigval sv) {} diff --git a/src/configure.ac b/src/configure.ac index c3935742f..b52aabcf9 100644 --- a/src/configure.ac +++ b/src/configure.ac @@ -3807,12 +3807,16 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM( dnl Check for timer_create. It probably requires the 'rt' library. dnl Run the program to find out if timer_create(CLOCK_MONOTONIC) actually dnl works, on Solaris timer_create() exists but fails at runtime. -AC_CACHE_CHECK([for timer_create], [vim_cv_timer_create], +AC_CACHE_CHECK([for timer_create], [vim_cv_timer_create], [ save_LIBS="$LIBS" LIBS="$LIBS -lrt" AC_RUN_IFELSE([AC_LANG_PROGRAM([ -#include -#include +#if STDC_HEADERS +# include +# include +#endif +#include +#include static void set_flag(union sigval sv) {} ], [ struct timespec ts; @@ -3827,6 +3831,10 @@ static void set_flag(union sigval sv) {} AC_MSG_NOTICE(timer_create with -lrt); vim_cv_timer_create=yes, LIBS="$save_LIBS" AC_RUN_IFELSE([AC_LANG_PROGRAM([ +#if STDC_HEADERS +# include +# include +#endif #include #include static void set_flag(union sigval sv) {} @@ -3843,7 +3851,7 @@ static void set_flag(union sigval sv) {} vim_cv_timer_create=yes, vim_cv_timer_create=no), AC_MSG_ERROR(cross-compiling: please set 'vim_cv_timer_create') - ) + )] ) if test "x$vim_cv_timer_create" = "xyes" ; then diff --git a/src/version.c b/src/version.c index 08152ad0c..e57686082 100644 --- a/src/version.c +++ b/src/version.c @@ -735,6 +735,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 98, /**/ 97, /**/ -- 2.40.0