#endif
])
-AC_CHECK_HEADERS(pwd.h grp.h sys/un.h ctype.h limits.h xfs/xqm.h fs_info.h fshelp.h paths.h mntent.h mnttab.h sys/fstyp.h sys/fs_types.h sys/mntent.h sys/mnttab.h sys/statfs.h sys/statvfs.h sys/vfs.h sys/vfstab.h kvm.h wordexp.h locale.h)
+AC_CHECK_HEADERS(pwd.h grp.h sys/un.h ctype.h limits.h xfs/xqm.h fs_info.h fshelp.h paths.h mntent.h mnttab.h sys/fstyp.h sys/fs_types.h sys/mntent.h sys/mnttab.h sys/statfs.h sys/statvfs.h sys/vfs.h sys/vfstab.h sys/vmmeter.h kvm.h wordexp.h locale.h)
# For the dns plugin
AC_CHECK_HEADERS(arpa/nameser.h)
#ifdef HAVE_SYS_SYSCTL_H
# include <sys/sysctl.h>
#endif
+#ifdef HAVE_SYS_VMMETER_H
+# include <sys/vmmeter.h>
+#endif
#ifdef HAVE_MACH_KERN_RETURN_H
# include <mach/kern_return.h>
static int conn_read (void)
{
struct inpcbtable table;
-#ifdef __OpenBSD__ || __NetBSD_Version__ > 699002700
+#if !defined(__OpenBSD__) && (defined(__NetBSD_Version__) && __NetBSD_Version__ <= 699002700)
struct inpcb *head;
#endif
struct inpcb *next;
if (status != 0)
return (-1);
-#ifdef __OpenBSD__ || __NetBSD_Version__ > 699002700
+#if defined(__OpenBSD__) || (defined(__NetBSD_Version__) && __NetBSD_Version__ > 699002700)
/* inpt_queue is a TAILQ on OpenBSD */
/* Get the first pcb */
next = (struct inpcb *)TAILQ_FIRST (&table.inpt_queue);
kread ((u_long) next, &inpcb, sizeof (inpcb));
/* Advance `next' */
-#ifdef __OpenBSD__ || __NetBSD_Version__ > 699002700
+#if defined(__OpenBSD__) || (defined(__NetBSD_Version__) && __NetBSD_Version__ > 699002700)
/* inpt_queue is a TAILQ on OpenBSD */
next = (struct inpcb *)TAILQ_NEXT (&inpcb, inp_queue);
#else