I recently updated my checkout to pull all of the new stable branches, and then tried to do a clean build using ./utils/build-script --xcode --release-debuginfo --debug-swift --skip-build-benchmarks --clean
. I've been running into issues where the build fails every time trying to link clang's diagtool. Has anyone run into something similar or have any advice on how to debug? It seems like some of the clang libs might be getting symlinked in the wrong places. It's kind of odd though because the corresponding ninja build (./utils/build-script --release-debuginfo --debug-swift --skip-build-benchmarks --clean
) succeeds. I've pasted the relevant output below. Any help would be much appreciated!
Edit: I'm running the final released version of Xcode 11.0 which I believe is still supported.
=== BUILD TARGET diagtool OF PROJECT LLVM WITH CONFIGURATION RelWithDebInfo ===
Check dependencies
Ld /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/bin/diagtool normal x86_64
cd /Users/owenvoorhees/Documents/Development/swift-source/llvm
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -target x86_64-apple-macos10.9 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -L/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/bin -F/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/bin -filelist /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/tools/clang/tools/diagtool/LLVM.build/RelWithDebInfo/diagtool.build/Objects-normal/x86_64/diagtool.LinkFileList -Xlinker -rpath -Xlinker @loader_path/../lib -Xlinker -object_path_lto -Xlinker /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/tools/clang/tools/diagtool/LLVM.build/RelWithDebInfo/diagtool.build/Objects-normal/x86_64/diagtool_lto.o -Wl,-dead_strip -Wl,-search_paths_first -Wl,-headerpad_max_install_names /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMSupport.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangBasic.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangFrontend.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangDriver.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangParse.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMMCParser.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangSerialization.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangSema.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangAPINotes.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangEdit.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangAnalysis.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangASTMatchers.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangAST.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangLex.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangBasic.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMMC.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMDebugInfoCodeView.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMDebugInfoMSF.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMBitReader.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMOption.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMProfileData.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMCore.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMBinaryFormat.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMRemarks.a /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMSupport.a -lz -lcurses -lm /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libLLVMDemangle.a -Xlinker -dependency_info -Xlinker /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/tools/clang/tools/diagtool/LLVM.build/RelWithDebInfo/diagtool.build/Objects-normal/x86_64/diagtool_dependency_info.dat -o /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/bin/diagtool
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangBasic.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangFrontend.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangDriver.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangParse.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangSerialization.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangSema.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangAPINotes.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangEdit.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangAnalysis.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangASTMatchers.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangAST.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangLex.a'
clang: error: no such file or directory: '/Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/lib/libclangBasic.a'
=== BUILD TARGET clangCrossTU OF PROJECT LLVM WITH CONFIGURATION RelWithDebInfo ===
Check dependencies
=== BUILD TARGET obj.clangRewrite OF PROJECT LLVM WITH CONFIGURATION RelWithDebInfo ===
Check dependencies
** BUILD FAILED **
The following build commands failed:
Ld /Users/owenvoorhees/Documents/Development/swift-source/build/Xcode-RelWithDebInfoAssert+swift-DebugAssert/llvm-macosx-x86_64/RelWithDebInfo/bin/diagtool normal x86_64
(1 failure)
./utils/build-script: fatal error: command terminated with a non-zero exit status 65, aborting