aboutsummaryrefslogtreecommitdiff
path: root/lib/portability.h
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2014-03-29 18:11:00 -0500
committerRob Landley <rob@landley.net>2014-03-29 18:11:00 -0500
commit5b405827a2fa4c928c488f3e7b0197dfec60dcc2 (patch)
treee8bbf1f2f4b8f70bd7e0682e0440ac64735096a4 /lib/portability.h
parentd4f01257d9d3b0d776114046a43d237a424fef77 (diff)
downloadtoybox-5b405827a2fa4c928c488f3e7b0197dfec60dcc2.tar.gz
Group headers by standard (POSIX or LSB) or function (internationalization, networking). Move headers standards ignore (but which have been there >15 years) to lib/portability.h. Fold xregcomp into lib since it's posix.
Diffstat (limited to 'lib/portability.h')
-rw-r--r--lib/portability.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/portability.h b/lib/portability.h
index 86484c7f..3b1cdf70 100644
--- a/lib/portability.h
+++ b/lib/portability.h
@@ -13,6 +13,9 @@
#undef _FORTIFY_SOURCE
+// For musl
+#define _ALL_SOURCE
+
// Test for gcc (using compiler builtin #define)
#ifdef __GNUC__
@@ -150,5 +153,10 @@ ssize_t getdelim(char **lineptr, size_t *n, int delim, FILE *stream);
ssize_t getline(char **lineptr, size_t *n, FILE *stream);
#endif
+// Linux headers not listed by POSIX or LSB
+#include <shadow.h>
+#include <sys/mount.h>
+#include <sys/swap.h>
+
// compile time probes for stuff libc didn't provide
#include "generated/portability.h"