aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2018-11-30 13:31:33 -0800
committerRob Landley <rob@landley.net>2018-11-30 16:38:12 -0600
commit890909a6d0ec2fa7f55afd22aa142b4b3d5f156a (patch)
tree8c68dc7fdcb3c2aa20339a1425b446aeeaaf09cc /lib
parentc6ee3c269e06fb0cfa61e759ed84b85e038593c7 (diff)
downloadtoybox-890909a6d0ec2fa7f55afd22aa142b4b3d5f156a.tar.gz
macOS: work around header idiosyncracies.
Diffstat (limited to 'lib')
-rw-r--r--lib/portability.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/portability.h b/lib/portability.h
index 3f841bac..21d0b8a1 100644
--- a/lib/portability.h
+++ b/lib/portability.h
@@ -147,7 +147,17 @@ int clearenv(void);
// Linux headers not listed by POSIX or LSB
#include <sys/mount.h>
+#ifdef __linux__
+#include <sys/statfs.h>
#include <sys/swap.h>
+#include <sys/sysinfo.h>
+#endif
+
+#ifdef __APPLE__
+#include <util.h>
+#else
+#include <pty.h>
+#endif
// Android is missing some headers and functions
// "generated/config.h" is included first