Edit: It seems like upgrading CMake to the latest stable version seems to have fixed the problem.
Summary
I am not sure if I am the only one, but there's seems to be an issue when building swift (fresh checkout). I am using Xcode 11.3.1 and macOS Catalina 10.15.3.
There seems to be a few errors actually when building with build-script -x -r --skip-build-benchmarks
(tried --clean
and --reconfigure
too but they make no difference):
-- Detecting CXX compile features - done
-- CMake (/usr/local/Cellar/cmake/3.12.4/bin/cmake) Version: 3.12.4
xcodebuild: error: invalid option '--version'
Call Stack (most recent call first):
cmake/modules/SwiftSharedCMakeConfig.cmake:102 (include)
cmake/modules/SwiftSharedCMakeConfig.cmake:207 (swift_common_standalone_build_config_llvm)
CMakeLists.txt:467 (swift_common_standalone_build_config)
CMake Error at cmake/modules/AddSwift.cmake:1394 (target_link_options):
Unknown CMake command "target_link_options".
Call Stack (most recent call first):
cmake/modules/AddSwift.cmake:2182 (_add_swift_library_single)
stdlib/toolchain/Compatibility50/CMakeLists.txt:3 (add_swift_target_library)
Did something change recently? Ninja has a similar issue (related to CMake) so it doesn't seem to be related to Xcode.