summaryrefslogtreecommitdiffstats
path: root/Source/cmStandardIncludes.h
diff options
context:
space:
mode:
authorKylie McClain <somasissounds@gmail.com>2015-11-25 23:12:06 (GMT)
committerBrad King <brad.king@kitware.com>2015-12-02 13:31:08 (GMT)
commit001043ac3078c49651f6af0f1ff1b31ef71a7665 (patch)
tree4043d56a38c8ff0bf1fc121bf0365bbe9d8fae05 /Source/cmStandardIncludes.h
parentb4a2ada297214119647b26df8abe394cd73ca53a (diff)
downloadCMake-001043ac3078c49651f6af0f1ff1b31ef71a7665.zip
CMake-001043ac3078c49651f6af0f1ff1b31ef71a7665.tar.gz
CMake-001043ac3078c49651f6af0f1ff1b31ef71a7665.tar.bz2
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.
Diffstat (limited to 'Source/cmStandardIncludes.h')
-rw-r--r--Source/cmStandardIncludes.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/cmStandardIncludes.h b/Source/cmStandardIncludes.h
index 468a589..e212616 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