This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "CMake".
The branch, master has been updated via 73657a35e6f64e530e8bbda90757c3762d7c36c6 (commit) via 88c9878af9d6d4b8cd3c7358bfdd12206c8aadb4 (commit) from 1d51fcaeafeb9bfcdf3bc871d2b875446df081e8 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=73657a35e6f64e530e8bbda90757c3762d7c36c6 commit 73657a35e6f64e530e8bbda90757c3762d7c36c6 Merge: 1d51fca 88c9878 Author: Brad King <brad.k...@kitware.com> AuthorDate: Fri Aug 11 13:16:59 2017 +0000 Commit: Kitware Robot <kwro...@kitware.com> CommitDate: Fri Aug 11 09:17:04 2017 -0400 Merge topic 'libuv-required' 88c9878a Make libuv available to all parts of CMake Acked-by: Kitware Robot <kwro...@kitware.com> Merge-request: !1104 https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=88c9878af9d6d4b8cd3c7358bfdd12206c8aadb4 commit 88c9878af9d6d4b8cd3c7358bfdd12206c8aadb4 Author: Brad King <brad.k...@kitware.com> AuthorDate: Thu Aug 3 14:47:49 2017 -0400 Commit: Brad King <brad.k...@kitware.com> CommitDate: Tue Aug 8 09:34:54 2017 -0400 Make libuv available to all parts of CMake The libuv library provides many useful platform abstractions and better process management than KWSys. We'd like to use it everywhere instead of just in the server mode. Drop the `CMAKE_USE_LIBUV` option and use libuv everywhere except during bootstrap. diff --git a/CMakeLists.txt b/CMakeLists.txt index 831e25f..e60dc78 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -529,42 +529,21 @@ macro (CMAKE_BUILD_UTILITIES) #--------------------------------------------------------------------- # Build libuv library. - if(NOT DEFINED CMAKE_USE_LIBUV) - set(CMAKE_USE_LIBUV 1) - if(APPLE) - include(CheckCSourceCompiles) - check_c_source_compiles(" -#include <CoreServices/CoreServices.h> -#include <AvailabilityMacros.h> -#ifndef MAC_OS_X_VERSION_10_5 -#error \"MAC_OS_X_VERSION_10_5 is not defined\" -#endif -int main(void) { return 0; } -" HAVE_CoreServices_OS_X_10_5) - if(NOT HAVE_CoreServices_OS_X_10_5) - set(CMAKE_USE_LIBUV 0) - endif() - endif() - endif() - if(CMAKE_USE_LIBUV) - if(CMAKE_USE_SYSTEM_LIBUV) - if(NOT CMAKE_VERSION VERSION_LESS 3.0) - find_package(LibUV 1.0.0) - else() - message(FATAL_ERROR "CMAKE_USE_SYSTEM_LIBUV requires CMake >= 3.0") - endif() - if(NOT LIBUV_FOUND) - message(FATAL_ERROR - "CMAKE_USE_SYSTEM_LIBUV is ON but a libuv is not found!") - endif() - set(CMAKE_LIBUV_LIBRARIES LibUV::LibUV) + if(CMAKE_USE_SYSTEM_LIBUV) + if(NOT CMAKE_VERSION VERSION_LESS 3.0) + find_package(LibUV 1.0.0) else() - set(CMAKE_LIBUV_LIBRARIES cmlibuv) - add_subdirectory(Utilities/cmlibuv) - CMAKE_SET_TARGET_FOLDER(cmlibuv "Utilities/3rdParty") + message(FATAL_ERROR "CMAKE_USE_SYSTEM_LIBUV requires CMake >= 3.0") endif() + if(NOT LIBUV_FOUND) + message(FATAL_ERROR + "CMAKE_USE_SYSTEM_LIBUV is ON but a libuv is not found!") + endif() + set(CMAKE_LIBUV_LIBRARIES LibUV::LibUV) else() - set(CMAKE_LIBUV_LIBRARIES) + set(CMAKE_LIBUV_LIBRARIES cmlibuv) + add_subdirectory(Utilities/cmlibuv) + CMAKE_SET_TARGET_FOLDER(cmlibuv "Utilities/3rdParty") endif() #--------------------------------------------------------------------- @@ -758,8 +737,7 @@ if(NOT CMake_TEST_EXTERNAL_CMAKE) if(NOT DEFINED CMake_ENABLE_SERVER_MODE) list(FIND CMAKE_CXX_COMPILE_FEATURES cxx_auto_type CMake_HAVE_CXX_AUTO_TYPE) list(FIND CMAKE_CXX_COMPILE_FEATURES cxx_range_for CMake_HAVE_CXX_RANGE_FOR) - if(CMAKE_USE_LIBUV - AND CMake_HAVE_CXX_AUTO_TYPE + if(CMake_HAVE_CXX_AUTO_TYPE AND CMake_HAVE_CXX_MAKE_UNIQUE AND CMake_HAVE_CXX_RANGE_FOR ) @@ -768,9 +746,6 @@ if(NOT CMake_TEST_EXTERNAL_CMAKE) set(CMake_ENABLE_SERVER_MODE 0) endif() endif() - if(CMake_ENABLE_SERVER_MODE AND NOT CMAKE_USE_LIBUV) - message(FATAL_ERROR "The server mode requires libuv!") - endif() else() set(CMake_ENABLE_SERVER_MODE 0) endif() diff --git a/Source/cmConfigure.cmake.h.in b/Source/cmConfigure.cmake.h.in index 524fdf8..302000a 100644 --- a/Source/cmConfigure.cmake.h.in +++ b/Source/cmConfigure.cmake.h.in @@ -19,7 +19,6 @@ #cmakedefine HAVE_UNSETENV #cmakedefine CMAKE_USE_ELF_PARSER #cmakedefine CMAKE_USE_MACH_PARSER -#cmakedefine CMAKE_USE_LIBUV #cmakedefine CMake_HAVE_CXX_AUTO_PTR #cmakedefine CMake_HAVE_CXX_EQ_DELETE #cmakedefine CMake_HAVE_CXX_FALLTHROUGH diff --git a/Source/cmakemain.cxx b/Source/cmakemain.cxx index c5a6836..dd88083 100644 --- a/Source/cmakemain.cxx +++ b/Source/cmakemain.cxx @@ -15,6 +15,11 @@ #ifdef CMAKE_BUILD_WITH_CMAKE #include "cmDocumentation.h" #include "cmDynamicLoader.h" +#ifdef _WIN32 +#include <fcntl.h> /* _O_TEXT */ +#include <stdlib.h> /* _set_fmode, _fmode */ +#endif +#include "cm_uv.h" #endif #include "cmsys/Encoding.hxx" @@ -26,14 +31,6 @@ #include <string> #include <vector> -#ifdef CMAKE_USE_LIBUV -#ifdef _WIN32 -#include <fcntl.h> /* _O_TEXT */ -#include <stdlib.h> /* _set_fmode, _fmode */ -#endif -#include "cm_uv.h" -#endif - #ifdef CMAKE_BUILD_WITH_CMAKE static const char* cmDocumentationName[][2] = { { CM_NULLPTR, " cmake - Cross-Platform Makefile Generator." }, @@ -172,7 +169,7 @@ int main(int ac, char const* const* av) ac = args.argc(); av = args.argv(); -#if defined(CMAKE_USE_LIBUV) && defined(_WIN32) +#if defined(CMAKE_BUILD_WITH_CMAKE) && defined(_WIN32) // Perform libuv one-time initialization now, and then un-do its // global _fmode setting so that using libuv does not change the // default file text/binary mode. See libuv issue 840. @@ -197,8 +194,6 @@ int main(int ac, char const* const* av) int ret = do_cmake(ac, av); #ifdef CMAKE_BUILD_WITH_CMAKE cmDynamicLoader::FlushCache(); -#endif -#ifdef CMAKE_USE_LIBUV uv_loop_close(uv_default_loop()); #endif return ret; ----------------------------------------------------------------------- Summary of changes: CMakeLists.txt | 51 +++++++++++------------------------------ Source/cmConfigure.cmake.h.in | 1 - Source/cmakemain.cxx | 17 +++++--------- 3 files changed, 19 insertions(+), 50 deletions(-) hooks/post-receive -- CMake _______________________________________________ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/mailman/listinfo/cmake-commits