2025-09-10 Bruno Haible <bruno@clisp.org>
+ nproc: Remove support for IRIX.
+ * lib/nproc.c: Remove code for IRIX.
+ * m4/nproc.m4 (gl_PREREQ_NPROC): Don't test for <sys/sysmp.h> and sysmp.
+
mprotect: Remove support for IRIX.
* m4/mprotect.m4 (gl_FUNC_MPROTECT_WORKS): Remove cross-compilation
guess for IRIX.
# include <sys/pstat.h>
#endif
-#if HAVE_SYS_SYSMP_H
-# include <sys/sysmp.h>
-#endif
-
#if HAVE_SYS_PARAM_H
# include <sys/param.h>
#endif
}
#endif
-#if HAVE_SYSMP && defined MP_NAPROCS && defined MP_NPROCS
- { /* This works on IRIX. */
- /* MP_NPROCS yields the number of installed processors.
- MP_NAPROCS yields the number of processors available to unprivileged
- processes. */
- int nprocs =
- sysmp (query == NPROC_CURRENT && getuid () != 0
- ? MP_NAPROCS
- : MP_NPROCS);
- if (nprocs > 0)
- return nprocs;
- }
-#endif
-
/* Finally, as fallback, use the APIs that don't distinguish between
NPROC_CURRENT and NPROC_ALL. */
# nproc.m4
-# serial 6
+# serial 7
dnl Copyright (C) 2009-2025 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
dnl Persuade glibc <sched.h> to declare CPU_SETSIZE, CPU_ISSET etc.
AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS])
- AC_CHECK_HEADERS([mntent.h sys/pstat.h sys/sysmp.h sys/param.h],,,
+ AC_CHECK_HEADERS([mntent.h sys/pstat.h sys/param.h],,,
[AC_INCLUDES_DEFAULT])
dnl <sys/sysctl.h> requires <sys/param.h> on OpenBSD 4.0.
AC_CHECK_HEADERS([sys/sysctl.h],,,
#endif
])
- AC_CHECK_FUNCS([sched_getaffinity_np pstat_getdynamic sysmp sysctl])
+ AC_CHECK_FUNCS([sched_getaffinity_np pstat_getdynamic sysctl])
gl_CHECK_FUNCS_ANDROID([sched_getaffinity], [[#include <sched.h>]])
dnl Test whether sched_getaffinity has the expected declaration.