diff options
Diffstat (limited to 'procps')
-rw-r--r-- | procps/free.c | 3 | ||||
-rw-r--r-- | procps/ps.c | 3 | ||||
-rw-r--r-- | procps/uptime.c | 4 |
3 files changed, 10 insertions, 0 deletions
diff --git a/procps/free.c b/procps/free.c index ca753134c..47f2fc3b2 100644 --- a/procps/free.c +++ b/procps/free.c | |||
@@ -22,6 +22,9 @@ | |||
22 | //usage: "Total: 386144 257128 129016\n" | 22 | //usage: "Total: 386144 257128 129016\n" |
23 | 23 | ||
24 | #include "libbb.h" | 24 | #include "libbb.h" |
25 | #ifdef __linux__ | ||
26 | # include <sys/sysinfo.h> | ||
27 | #endif | ||
25 | 28 | ||
26 | struct globals { | 29 | struct globals { |
27 | unsigned mem_unit; | 30 | unsigned mem_unit; |
diff --git a/procps/ps.c b/procps/ps.c index 7537118f6..dcc0f7bd4 100644 --- a/procps/ps.c +++ b/procps/ps.c | |||
@@ -62,6 +62,9 @@ enum { MAX_WIDTH = 2*1024 }; | |||
62 | 62 | ||
63 | #if ENABLE_DESKTOP | 63 | #if ENABLE_DESKTOP |
64 | 64 | ||
65 | #ifdef __linux__ | ||
66 | # include <sys/sysinfo.h> | ||
67 | #endif | ||
65 | #include <sys/times.h> /* for times() */ | 68 | #include <sys/times.h> /* for times() */ |
66 | #ifndef AT_CLKTCK | 69 | #ifndef AT_CLKTCK |
67 | # define AT_CLKTCK 17 | 70 | # define AT_CLKTCK 17 |
diff --git a/procps/uptime.c b/procps/uptime.c index 1a7da46a3..74323625d 100644 --- a/procps/uptime.c +++ b/procps/uptime.c | |||
@@ -25,6 +25,10 @@ | |||
25 | //usage: " 1:55pm up 2:30, load average: 0.09, 0.04, 0.00\n" | 25 | //usage: " 1:55pm up 2:30, load average: 0.09, 0.04, 0.00\n" |
26 | 26 | ||
27 | #include "libbb.h" | 27 | #include "libbb.h" |
28 | #ifdef __linux__ | ||
29 | # include <sys/sysinfo.h> | ||
30 | #endif | ||
31 | |||
28 | 32 | ||
29 | #ifndef FSHIFT | 33 | #ifndef FSHIFT |
30 | # define FSHIFT 16 /* nr of bits of precision */ | 34 | # define FSHIFT 16 /* nr of bits of precision */ |