<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi,<div class=""><br class=""></div><div class="">I am following the Getting Started page at&nbsp;<a href="https://swift.org/getting-started" class="">https://swift.org/getting-started</a>&nbsp;and I have a problem when arriving at “Using the build system”.</div><div class=""><br class=""></div><div class="">When I type the “swift build —help” command, I get the following error:</div><div class=""><br class=""></div><div class=""><blockquote type="cite" class=""><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class="">$ swift build --help</div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class="">error: unable to invoke subcommand: /Library/Developer/Toolchains/swift-2.2-SNAPSHOT-2016-02-08-a.xctoolchain/usr/bin/swift-build (No such file or directory)</div></blockquote></div><div class=""><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><br class=""></div></div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class="">And indeed the diagnostic is right: there is no binary named swift-build there.</div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><br class=""></div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class="">Here is what I did:</div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><br class=""></div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class="">- I downloaded from&nbsp;<a href="https://swift.org/download/:" class="">https://swift.org/download/:</a></div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class=""><br class=""></div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class="">• the Xcode Swift Development Snapshot (dated February 8, 2016)</div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class="">• its Debugging symbols</div><div style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;" class="">• the&nbsp;Xcode Swift 2.2 Snapshot (dated February 8, 2016)</div><div style="margin: 0px; line-height: normal;" class=""><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class="">• its Debugging symbols</div><div style="font-family: Menlo; font-size: 11px;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class="">- I installed all four packages for all users.</div><div style="font-family: Menlo; font-size: 11px;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class="">- I changed my PATH as suggested:</div><div style="font-family: Menlo; font-size: 11px;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class=""><blockquote type="cite" class=""><div style="margin: 0px; line-height: normal;" class="">$ export PATH=/Library/Developer/Toolchains/swift-latest.xctoolchain/usr/bin:"${PATH}"</div></blockquote></div><div style="font-family: Menlo; font-size: 11px;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class="">- I ran Xcode 7.3B3, and selected the toolchain named "Xcode Swift Development Snapshot 2016-02-08 (a)”</div><div style="font-family: Menlo; font-size: 11px;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class="">Xcode restarted and seems OK with it, with the new button in the toolbar as expect</div><div style="font-family: Menlo; font-size: 11px;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class="">- I checked the /Library/Developer/Content:</div><div style="font-family: Menlo; font-size: 11px;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class=""><blockquote type="cite" class=""><div style="margin: 0px; line-height: normal;" class="">$ cd /Library/Developer/Toolchains/</div><div style="margin: 0px; line-height: normal;" class="">$ ls -la</div><div style="margin: 0px; line-height: normal;" class="">total 8</div><div style="margin: 0px; line-height: normal;" class="">drwxr-xr-x&nbsp; 5 root&nbsp; wheel&nbsp; 170 Feb 11 11:34 .</div><div style="margin: 0px; line-height: normal;" class="">drwxr-xr-x&nbsp; 5 root&nbsp; admin&nbsp; 170 Feb 11 11:14 ..</div><div style="margin: 0px; line-height: normal;" class="">drwxr-xr-x&nbsp; 6 root&nbsp; wheel&nbsp; 204 Feb 11 11:34 swift-2.2-SNAPSHOT-2016-02-08-a.xctoolchain</div><div style="margin: 0px; line-height: normal;" class="">drwxr-xr-x&nbsp; 6 root&nbsp; wheel&nbsp; 204 Feb 11 11:27 swift-DEVELOPMENT-SNAPSHOT-2016-02-08-a.xctoolchain</div><div style="margin: 0px; line-height: normal;" class="">lrwxr-xr-x&nbsp; 1 root&nbsp; wheel &nbsp; 73 Feb 11 11:34 swift-latest.xctoolchain -&gt; /Library/Developer/Toolchains/swift-2.2-SNAPSHOT-2016-02-08-a.xctoolchain</div></blockquote></div><div style="font-family: Menlo; font-size: 11px;" class=""><div style="margin: 0px; line-height: normal;" class=""><br class=""></div></div><div style="font-family: Menlo; font-size: 11px;" class="">- I checked the current swift:</div><div style="font-family: Menlo; font-size: 11px;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class=""><blockquote type="cite" class=""><div style="margin: 0px; line-height: normal;" class="">$ which swift</div><div style="margin: 0px; line-height: normal;" class="">/Library/Developer/Toolchains/swift-latest.xctoolchain/usr/bin/swift</div><div style="margin: 0px; line-height: normal;" class="">$ swift --version</div><div style="margin: 0px; line-height: normal;" class="">Apple Swift version 2.2-dev (LLVM ee6c2618e5, Clang 9b95f4af98, Swift d45cca1dc1)</div><div style="margin: 0px; line-height: normal;" class="">Target: x86_64-apple-macosx10.9</div></blockquote><br class=""></div><div style="font-family: Menlo; font-size: 11px;" class="">(So it seems the selected toolchain in Xcode doesn’t correspond to the toolchain pointed to by the swift-latest.xctoolchain symbolic link. Fine)</div><div style="font-family: Menlo; font-size: 11px;" class=""><div style="margin: 0px; line-height: normal;" class=""><br class=""></div></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class="">- I went back to Xcode and noticed a button in the toolchain preference pane that appears when hovering over it. Clicking it shows a pop-up with the option to “Verify code signature…”. Doing it yielded the following error:</div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><blockquote type="cite" class="">“Xcode Swift DEVELOPMENT Snapshot 2016-02-08 (a)” does not have a valid signature: a sealed resource is missing or invalid</blockquote><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class="">This for both installed toolchains</div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><blockquote type="cite" style="font-family: Helvetica; font-size: 12px;" class="">“Xcode Swift 2.2 Snapshot 2016-02-08 (a)” does not have a valid signature: a sealed resource is missing or invalid</blockquote><div class=""><br class=""></div></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class="">- I tried to prefix swift with xcrun, which shows xcrun doesn’t respect the selected toolchain:</div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><blockquote type="cite" class=""><div style="margin: 0px; line-height: normal;" class="">$ xcrun swift --version</div><div style="margin: 0px; line-height: normal;" class="">Apple Swift version 2.2 (swiftlang-703.0.6.5 clang-703.0.21)</div><div style="margin: 0px; line-height: normal;" class="">Target: x86_64-apple-macosx10.9</div><div style="margin: 0px; line-height: normal;" class="">$ swift --version</div><div style="margin: 0px; line-height: normal;" class="">Apple Swift version 2.2-dev (LLVM ee6c2618e5, Clang 9b95f4af98, Swift d45cca1dc1)</div><div style="margin: 0px; line-height: normal;" class="">Target: x86_64-apple-macosx10.9</div></blockquote><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class="">So are the snapshots really broken? Or is it Xcode signature check that is broken?\</div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class="">Where is my swift-build?</div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class="">Thanks,</div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class="">Jean-Denis</div><div style="font-family: Menlo; font-size: 11px; margin: 0px; line-height: normal;" class=""><br class=""></div></div></body></html>