diff --git a/CMakeLists.txt b/CMakeLists.txt index cad3a235..583ac2f9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,9 +17,13 @@ set(CMAKE_Swift_MODULE_DIRECTORY ${CMAKE_BINARY_DIR}/swift) include(CTest) include(SwiftSupport) -find_package(dispatch CONFIG) -find_package(Foundation CONFIG) -find_package(XCTest CONFIG) +if(NOT APPLE) + find_package(dispatch CONFIG) + find_package(Foundation CONFIG) + if(BUILD_TESTING) + find_package(XCTest CONFIG) + endif() +endif() add_subdirectory(Sources) if(BUILD_EXAMPLES)