<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="">If you build swift yourself you need to point directly at swift-build. Most people grab the pre-built toolchains from <a href="http://swift.org" class="">swift.org</a> to start trying things out. Have you seen the instructions here:<div class=""> <a href="https://swift.org/download/#using-downloads" class="">https://swift.org/download/#using-downloads</a></div><div class=""><br class=""></div><div class=""> - Daniel</div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Apr 3, 2016, at 7:27 PM, Shawn Erickson via swift-users <<a href="mailto:swift-users@swift.org" class="">swift-users@swift.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class=""><span class=""><div style="" class=""><div class=""><span class=""><div class="">It isn't very clear what you have done or what you are actually doing. The path "path/to/bin/swift build" doesn't make much sense, it must be an example trying to imply you need to supply the path to the actual swift command on your system.</div><div class=""><br class=""></div><div class="">Review <a href="https://github.com/apple/swift-package-manager/blob/master/README.md" class="">https://github.com/apple/swift-package-manager/blob/master/README.md</a>.</div><div class=""><br class=""></div><div class="">On my system with Xcode 7.3 installed as well as the 03-01 swift snapshot...</div><div class=""><br class=""></div><div class="">[shawnce:~/]</div><div class="">[1:539]> xcodebuild -version</div><div class="">Xcode 7.3</div><div class="">Build version 7D175</div><div class=""><br class=""></div></span></div><div class="">[shawnce:~/]</div><div class="">[1:540]> xcrun --find swift</div><div class="">/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift</div></div><div style="" class=""><br class=""></div><div style="" class="">[shawnce:~/]</div><div style="" class="">[1:541]> swift --version</div><div style="" class="">Apple Swift version 2.2 (swiftlang-703.0.18.1 clang-703.0.29)</div><div style="" class="">Target: x86_64-apple-macosx10.9</div><div style="" class=""><br class=""></div><div style="" class=""><span class=""><div class="">[shawnce:~/]</div><div class="">[1:542]> swift build</div><div class="">error: unable to invoke subcommand: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift-build (No such file or directory)</div></span></div><div style="" class=""><br class=""></div><div style="" class="">[shawnce:~/]</div><div style="" class="">[1:543]> export TOOLCHAINS=swift</div><div style="" class=""><br class=""></div><div style="" class="">[shawnce:~/]</div><div style="" class="">[1:544]> xcrun --find swift</div><div style="" class="">/Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-03-01-a.xctoolchain/usr/bin/swift</div><div style="" class=""><br class=""></div><div style="" class="">[shawnce:~/]</div><div style="" class="">[1:545]> swift --version</div><div style="" class="">Apple Swift version 3.0-dev (LLVM b361b0fc05, Clang 11493b0f62, Swift 24a0c3de75)</div><div style="" class="">Target: x86_64-apple-macosx10.9</div><div style="" class=""><br class=""></div><div style="" class=""><span class=""><div class="">[shawnce:~/]</div><div class="">[1:554]> swift build</div><div class="">error: no Package.swift file found << which is expect since I don't have a package in this directory.</div></span><br class=""></div></span><br class=""></div><br class=""><div class="gmail_quote"><div dir="ltr" class="">On Sun, Apr 3, 2016 at 6:51 PM Dave Yost via swift-users <<a href="mailto:swift-users@swift.org" class="">swift-users@swift.org</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word" class=""><div class="">This happens with the swift in Xcode 7.3 on 10.11.4, and it happens with the swift I just built from <a href="http://github.com/apple/swift" target="_blank" class="">http://github.com/apple/swift</a></div><div class=""><br class=""></div><div class=""><div style="margin:0px;font-size:8.5px;line-height:normal;font-family:Menlo;color:rgb(255,207,130);background-color:rgb(4,22,16)" class=""><span style="font-size:8.5px" class="">$ </span><span style="color:rgb(179,254,255);font-size:8.5px" class="">/path/to/bin/swift build</span></div><div style="margin:0px;font-size:8.5px;line-height:normal;font-family:Menlo;color:rgb(255,255,255);background-color:rgb(4,22,16)" class=""><span class="">error: unable to invoke subcommand: /path-to/bin/swift-build (No such file or directory)</span></div><div style="margin:0px;font-size:8.5px;line-height:normal;font-family:Menlo;color:rgb(255,207,130);background-color:rgb(4,22,16)" class=""><span class="">$</span></div></div><div class=""><br class=""></div><div class="">There is no file called “swift-build” anywhere on my system.</div><div class=""><br class=""></div><div class="">How do I fix this?</div><div class=""><br class=""></div><div class="">Thanks</div></div>_______________________________________________<br class="">
swift-users mailing list<br class="">
<a href="mailto:swift-users@swift.org" target="_blank" class="">swift-users@swift.org</a><br class="">
<a href="https://lists.swift.org/mailman/listinfo/swift-users" rel="noreferrer" target="_blank" class="">https://lists.swift.org/mailman/listinfo/swift-users</a><br class="">
</blockquote></div>
_______________________________________________<br class="">swift-users mailing list<br class=""><a href="mailto:swift-users@swift.org" class="">swift-users@swift.org</a><br class="">https://lists.swift.org/mailman/listinfo/swift-users<br class=""></div></blockquote></div><br class=""></div></body></html>