Add ALLPERMS and DEFFILEMODE to enable building on hosts with the musl c library

This commit is contained in:
Niels Sascha Reedijk
2018-04-30 11:11:11 +00:00
parent eaa5720b74
commit 2284eb4875
+8 -1
View File
@@ -7,11 +7,18 @@
# endif
#endif
#if defined(HAIKU_HOST_PLATFORM_CYGWIN) || defined(HAIKU_HOST_PLATFORM_SUNOS)
// DEFFILEMODE is not available on Cygwin, SunOS and when building with musl c
#if defined(HAIKU_HOST_PLATFORM_CYGWIN) || defined(HAIKU_HOST_PLATFORM_SUNOS) \
|| !defined(DEFFILEMODE)
#ifndef DEFFILEMODE
#define DEFFILEMODE (S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH)
#endif
// There's no ALLPERMS when building with musl c
#ifndef ALLPERMS
# define ALLPERMS (S_ISUID|S_ISGID|S_ISVTX|S_IRWXU|S_IRWXG|S_IRWXO)
#endif
#ifndef S_IUMSK
#define S_IUMSK 07777
#endif