aboutsummaryrefslogtreecommitdiff
path: root/lib/portability.h
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2014-09-06 13:24:58 -0500
committerRob Landley <rob@landley.net>2014-09-06 13:24:58 -0500
commit980458f62748d273a006da3ddcd2b619d44598ce (patch)
tree338d9604b25771d3b206e956b26f13538a3934f0 /lib/portability.h
parent9bb73ade0bb019c0819052d27c34959ec55dbe02 (diff)
downloadtoybox-980458f62748d273a006da3ddcd2b619d44598ce.tar.gz
Work around uClibc brain-damage.
Diffstat (limited to 'lib/portability.h')
-rw-r--r--lib/portability.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/portability.h b/lib/portability.h
index 07cb276b..866d9a4d 100644
--- a/lib/portability.h
+++ b/lib/portability.h
@@ -75,6 +75,18 @@ char *strptime(const char *buf, const char *format, struct tm *tm);
#include <stdio.h>
ssize_t getdelim(char **lineptr, size_t *n, int delim, FILE *stream);
+// uClibc's last-ever release was in 2012, so of course it doesn't define
+// any flag newer than MS_MOVE, which was added in 2001 (linux 2.5.0.5),
+// eleven years earlier.
+
+#define MS_MOVE (1<<13)
+#define MS_REC (1<<14)
+#define MS_SILENT (1<<15)
+#define MS_UNBINDABLE (1<<17)
+#define MS_PRIVATE (1<<18)
+#define MS_SLAVE (1<<19)
+#define MS_SHARED (1<<20)
+
// When building under obsolete glibc (Ubuntu 8.04-ish), hold its hand a bit.
#elif __GLIBC__ == 2 && __GLIBC_MINOR__ < 10
#define fstatat fstatat64