From b7f0b1240f9c251d059fafcde878168f2b9a6664 Mon Sep 17 00:00:00 2001 From: Eric Berge Date: Wed, 21 Dec 2016 15:38:28 -0600 Subject: libuv requires _XOPEN_SOURCE 600 on Solaris 11 This avoid build errors from the /usr/include/sys/feature_tests.h include file which disallows setting XOpen versions less than 6 when in C99 mode. --- Utilities/cmlibuv/CMakeLists.txt | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Utilities/cmlibuv/CMakeLists.txt b/Utilities/cmlibuv/CMakeLists.txt index 1b384b5..a8e25ba 100644 --- a/Utilities/cmlibuv/CMakeLists.txt +++ b/Utilities/cmlibuv/CMakeLists.txt @@ -218,8 +218,16 @@ if(CMAKE_SYSTEM_NAME STREQUAL "SunOS") ) list(APPEND uv_defines __EXTENSIONS__ - _XOPEN_SOURCE=500 ) + if(CMAKE_SYSTEM_VERSION STREQUAL "5.10") + list(APPEND uv_defines + _XOPEN_SOURCE=500 + ) + else() + list(APPEND uv_defines + _XOPEN_SOURCE=600 + ) + endif() list(APPEND uv_sources src/unix/sunos.c ) -- cgit v0.12