diff --git a/CMakeLists.txt b/CMakeLists.txt index 2bb1099078..46b757e5a0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -40,7 +40,7 @@ set(CMAKE_Swift_MODULE_DIRECTORY ${CMAKE_BINARY_DIR}/swift) option(BUILD_SHARED_LIBS "build shared libraries" ON) option(HAS_LIBDISPATCH_API "has libdispatch API" ON) option(BUILD_NETWORKING "build FoundationNetworking module" ON) -option(BUILD_TOOLS "build tools" ON) +option(FOUNDATION_BUILD_TOOLS "build tools" ON) option(NS_CURL_ASSUME_FEATURES_MISSING "Assume that optional libcurl features are missing rather than test the library's version, for build debugging" NO) if(HAS_LIBDISPATCH_API) diff --git a/Sources/CMakeLists.txt b/Sources/CMakeLists.txt index ab3a1bef11..93c067d261 100644 --- a/Sources/CMakeLists.txt +++ b/Sources/CMakeLists.txt @@ -2,4 +2,6 @@ add_subdirectory(UUID) add_subdirectory(Foundation) add_subdirectory(FoundationNetworking) add_subdirectory(FoundationXML) -add_subdirectory(Tools) +if(FOUNDATION_BUILD_TOOLS) + add_subdirectory(Tools) +endif()