<html><head><style>body{font-family:Helvetica,Arial;font-size:13px}</style></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">I think Greg is right. I’ve seen this before, and the way I fixed it was by fixing the Xcode configuration, specifically relating to the command-line tools.</div> <br> <div class="bloop_sign" id="bloop_sign_1481232398048780800"><div style="font-family:helvetica,arial;font-size:13px">- Will</div></div> <br><p class="airmail_on">On December 8, 2016 at 1:24:59 PM, Greg Parker via swift-dev (<a href="mailto:swift-dev@swift.org">swift-dev@swift.org</a>) wrote:</p> <blockquote type="cite" class="clean_bq"><span><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div></div><div>
<title></title>
<br class="">
<div>
<blockquote type="cite" class="">
<div class="">On Dec 8, 2016, at 7:28 AM, Frederick Kellison-Linn
via swift-dev <<a href="mailto:swift-dev@swift.org" class="">swift-dev@swift.org</a>> wrote:</div>
<br class="Apple-interchange-newline">
<div class="">
<div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hello,
<div class=""><br class=""></div>
<div class="">I have been attempting to build Swift, but have been
running into issues near the end of the build. Specifically, CMake
fails on the step <font face="Menlo" class="">[2112/2254]
Performing configure step for 'compiler-rt’</font>, since the
compiled <font face="Menlo" class="">clang</font> fails to
build a simple C program. The specific issue appears to be at the
lines:</div>
<div class=""><br class=""></div>
<div class="">
<div class=""><font face="Menlo" class="">ld: unexpected token:
!tapi-tbd-v2 file</font></div>
<div class=""><font face="Menlo" class="">
'/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/usr/lib/libSystem.tbd'</font></div>
<div class=""><font face="Menlo" class=""> for architecture
x86_64</font></div>
</div>
<div class=""><font face="Menlo" class=""><br class=""></font></div>
<div class="">My system settings are as follows:</div>
<div class=""><br class=""></div>
<div class="">MacBook Pro (Retina, Mid 2012)</div>
<div class="">macOS Sierra Version 10.12.2 Beta (16C48b)</div>
<div class="">Xcode Version 8.1 (8B62)</div>
<div class=""> |----clang/clang++: Apple LLVM
version 8.0.0 (clang-800.0.42.1)</div>
</div>
</div>
</blockquote>
<blockquote type="cite" class=""><br class=""></blockquote>
<blockquote type="cite" class="">
<div class="">
<div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">
<div class="">
<div class=""><font face="Menlo" class="">
/Users/freddy/Development/swift/swift-source/build/Ninja-RelWithDebInfoAssert/llvm-macosx-x86_64/./bin/clang</font></div>
<div class=""><font face="Menlo" class="">
-isysroot</font></div>
<div class=""><font face="Menlo" class="">
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk</font></div>
<div class=""><font face="Menlo" class="">
-Wl,-search_paths_first
-Wl,-headerpad_max_install_names</font></div>
<div class=""><font face="Menlo" class="">
CMakeFiles/cmTC_b980a.dir/testCCompiler.c.o -o cmTC_b980a
&& :</font></div>
<div class=""><font face="Menlo" class=""><br class=""></font></div>
<div class=""><font face="Menlo" class=""> ld: unexpected
token: !tapi-tbd-v2 file</font></div>
<div class=""><font face="Menlo" class="">
'/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/usr/lib/libSystem.tbd'</font></div>
<div class=""><font face="Menlo" class=""> for architecture
x86_64</font></div>
</div>
</div>
</div>
</blockquote>
</div>
<div><br class=""></div>
<div>That error sounds like the build is trying to use an old
linker that does not understand the format of the current SDK's
files.</div>
<div><br class=""></div>
<div>Xcode 8.1 (8B62) should be fine. If the problem is an old
linker then it is most likely coming from some other install of
Xcode on your machine.</div>
<div><br class=""></div>
<div>What is the output of `xcode-select -p` and `xcodebuild
-version`? If those are pointing at some other install of Xcode
then you can use `xcode-select -s` to tell the command-line tools
which copy of Xcode to use.</div>
<div><br class=""></div>
<div>You can also re-run the failing clang command by hand and add
-### to its arguments. clang will then print the full path to the
linker it is running.</div>
<div><br class=""></div>
<div><br class=""></div>
<div>-- </div>
<div>Greg Parker <a href="mailto:gparker@apple.com" class="">gparker@apple.com</a> Runtime Wrangler</div>
<div><br class=""></div>
<div><br class=""></div>
_______________________________________________<br>swift-dev mailing list<br>swift-dev@swift.org<br>https://lists.swift.org/mailman/listinfo/swift-dev<br></div></div></span></blockquote></body></html>