[#if HAVE_SYS_PARAM_H
#include <sys/param.h>
#endif]])
- AC_CHECK_HEADERS_ONCE([utmp.h utmpx.h OS.h])
+ AC_CHECK_HEADERS_ONCE([utmpx.h OS.h])
AC_CACHE_CHECK(
[whether we can get the system boot time],
[gnulib_cv_have_boot_time],
#endif
#if HAVE_UTMPX_H
# include <utmpx.h>
-#elif HAVE_UTMP_H
-# include <utmp.h>
#endif
+#include <utmp.h>
#if HAVE_OS_H
# include <OS.h>
#endif
}
#endif
-#if HAVE_UTMPX_H || HAVE_UTMP_H
+#if HAVE_STRUCT_UTMP_UT_TYPE || HAVE_STRUCT_UTMPX_UT_TYPE
/* Loop through all the utmp entries we just read and count up the valid
ones, also in the process possibly gleaning boottime. */
while (n--)
size_t n_users;
STRUCT_UTMP *utmp_buf = NULL;
-#if HAVE_UTMPX_H || HAVE_UTMP_H
+#if HAVE_STRUCT_UTMP_UT_TYPE || HAVE_STRUCT_UTMPX_UT_TYPE
if (read_utmp (filename, &n_users, &utmp_buf, options) != 0)
die (EXIT_FAILURE, errno, "%s", quotef (filename));
#endif