summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKylie McClain <somasissounds@gmail.com>2015-11-25 18:12:06 -0500
committerBrad King <brad.king@kitware.com>2015-12-02 08:31:08 -0500
commit001043ac3078c49651f6af0f1ff1b31ef71a7665 (patch)
tree4043d56a38c8ff0bf1fc121bf0365bbe9d8fae05
parentb4a2ada297214119647b26df8abe394cd73ca53a (diff)
downloadcmake-001043ac3078c49651f6af0f1ff1b31ef71a7665.tar.gz
Include `sys/types.h` header to get `mode_t`
Do not depend on it being included by other system headers. It is not included by others on musl-libc, for example.
-rw-r--r--Source/cmStandardIncludes.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/cmStandardIncludes.h b/Source/cmStandardIncludes.h
index 468a58908d..e21261652a 100644
--- a/Source/cmStandardIncludes.h
+++ b/Source/cmStandardIncludes.h
@@ -54,6 +54,8 @@
#if defined( _MSC_VER )
typedef unsigned short mode_t;
+#else
+# include <sys/types.h>
#endif
// use this class to shrink the size of symbols in .o files