aboutsummaryrefslogtreecommitdiff
path: root/testing/nmon/glibc.patch
diff options
context:
space:
mode:
Diffstat (limited to 'testing/nmon/glibc.patch')
-rw-r--r--testing/nmon/glibc.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/testing/nmon/glibc.patch b/testing/nmon/glibc.patch
new file mode 100644
index 0000000000..9418f2d421
--- /dev/null
+++ b/testing/nmon/glibc.patch
@@ -0,0 +1,29 @@
1From: Mike Crute <mike@crute.us>
2Date: Sun, 31 May 2020 19:26:32 +0000
3Subject: [PATCH] Add glibc compatibility to nmon
4
5musl is missing some compatibility with glibc which this patch adds to the nmon
6source. The fstab.h header was not used and fails to build if it's included.
7
8---
9
10--- a/lmon.c
11+++ b/lmon.c
12@@ -42,6 +42,9 @@
13 pi_delayacct_blkio_ticks
14 */
15
16+/* Fix compatibility for glibc */
17+#define __STRING(x) #x
18+
19 /* note: RAW assumes you are using the index "i" to select the CPU */
20 #define RAW(member) (long)((long)(p->cpuN[i].member) - (long)(q->cpuN[i].member))
21 #define RAWTOTAL(member) (long)((long)(p->cpu_total.member) - (long)(q->cpu_total.member))
22@@ -583,7 +586,6 @@
23 int isroot = 0;
24
25 #include <mntent.h>
26-#include <fstab.h>
27 #include <sys/stat.h>
28 #include <sys/statfs.h>
29 #include <net/if.h>