From e2982d691186c8a9b16ecc8d831d2472088c8ed8 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 6 Oct 2021 11:27:21 +0100 Subject: patch 8.2.3483: #ifdef for using sysinfo() is incomplete Problem: #ifdef for using sysinfo() is incomplete. Solution: Also check for HAVE_SYSINFO. Make autoconf check use TRY_LINK. (closes #8952) --- src/configure.ac | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/configure.ac') diff --git a/src/configure.ac b/src/configure.ac index d417b9046..bb77485f3 100644 --- a/src/configure.ac +++ b/src/configure.ac @@ -4113,9 +4113,10 @@ AC_TRY_COMPILE( AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SYSCTL), AC_MSG_RESULT(not usable)) -dnl sysinfo() may exist but not be Linux compatible +dnl sysinfo() may exist but not be Linux compatible. +dnl On some FreeBSD systems it may depend on libsysinfo, use TRY_LINK AC_MSG_CHECKING(for sysinfo) -AC_TRY_COMPILE( +AC_TRY_LINK( [#include #include ], [ struct sysinfo sinfo; -- cgit v1.2.1