Problem: configure: terminfo test does not work with musl
(T3rm1, after v9.9.1.0837)
Solution: include term.h in configure script, add forward declarations,
in case headers are not found
fixes: #18393
closes: #18405
Signed-off-by: Christian Brabandt <cb@256bit.org>
/* end confdefs.h. */
#include "confdefs.h"
-#ifdef HAVE_TERMCAP_H
+#ifdef HAVE_TERM_H
+# include <term.h>
+#elif defined(HAVE_TERMCAP_H)
# include <termcap.h>
+#else
+ /* forward declare tgoto */
+ extern char *tgoto(const char *, int, int);
#endif
#ifdef HAVE_STRING_H
# include <string.h>
[
AC_RUN_IFELSE([AC_LANG_SOURCE([[
#include "confdefs.h"
-#ifdef HAVE_TERMCAP_H
+#ifdef HAVE_TERM_H
+# include <term.h>
+#elif defined(HAVE_TERMCAP_H)
# include <termcap.h>
+#else
+ /* forward declare tgoto */
+ extern char *tgoto(const char *, int, int);
#endif
#ifdef HAVE_STRING_H
# include <string.h>
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1794,
/**/
1793,
/**/