summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1996-10-22 05:01:13 +0000
committerJim Meyering <jim@meyering.net>1996-10-22 05:01:13 +0000
commit330d1dc984266784153b0d9b59334344fb999f0a (patch)
treed0736593e7c995b41fa7fedb996e1dbe66d90f3d
parent365edb599f909f545aa2bfcc0fb74ed7621b334d (diff)
downloadgnulib-330d1dc984266784153b0d9b59334344fb999f0a.tar.gz
[__linux__]: Don't bother with a.out/nlist/kernelSH-UTILS-1_12p
defines or includes -- Linux systems simply read /proc/loadavg.
-rw-r--r--lib/getloadavg.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/getloadavg.c b/lib/getloadavg.c
index 6209fef76f..dae189ffe5 100644
--- a/lib/getloadavg.c
+++ b/lib/getloadavg.c
@@ -390,6 +390,7 @@ extern int errno;
#ifdef LOAD_AVE_TYPE
#ifndef VMS
+#ifndef __linux__
#ifndef NLIST_STRUCT
#include <a.out.h>
#else /* NLIST_STRUCT */
@@ -409,6 +410,7 @@ extern int errno;
#ifndef LDAV_SYMBOL
#define LDAV_SYMBOL "_avenrun"
#endif /* LDAV_SYMBOL */
+#endif /* __linux__ */
#else /* VMS */
@@ -495,7 +497,7 @@ static int getloadavg_initialized;
/* Offset in kmem to seek to read load average, or 0 means invalid. */
static long offset;
-#if !defined(VMS) && !defined(sgi)
+#if !defined(VMS) && !defined(sgi) && !defined(__linux__)
static struct nlist nl[2];
#endif /* Not VMS or sgi */