<div dir="ltr"><div>OSx version: 10.12.6 (16G29)</div><div>Steps to reproduce the error:</div><div>1)</div><div><pre style="box-sizing:border-box;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:13.6px;margin-top:0px;margin-bottom:16px;font-stretch:normal;line-height:1.45;word-wrap:normal;padding:16px;overflow:auto;background-color:rgb(246,248,250);border-radius:3px;color:rgb(36,41,46)"><code style="box-sizing:border-box;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:13.6px;padding:0px;margin:0px;background:transparent;border-radius:3px;word-break:normal;border:0px;display:inline;overflow:visible;line-height:inherit;word-wrap:normal">git clone <a href="https://github.com/apple/swift.git">https://github.com/apple/swift.git</a>
./swift/utils/update-checkout --clone --scheme swift-4.0-branch</code></pre></div><div>2) Edit build-preset.ini to remove tests and assertions:</div><div><br></div><div><div>[preset: mixin_lightweight_assertions]</div><div>#assertions</div><div>#no-swift-stdlib-assertions</div><div>no-assertions</div><div>swift-assertions</div></div><div>....</div><div><br></div><div><div>[preset: buildbot_osx_package]</div><div>mixin-preset=</div><div> mixin_osx_package_base</div><div> mixin_lightweight_assertions</div></div><div> ...</div><div><br></div><div>3) Execute: ./swift/util/build-toolchain local.swift</div><div><br></div><div>Error:</div><div><br></div><div>/bin/sh -c $HOME/swift-4.0/build/Ninja+<wbr>cmark-RelWithDebInfo+llvm-<wbr>RelWithDebInfo+swift-<wbr>RelWithDebInfoAssert+stdlib-<wbr>RelWithDebInfo/lldb-macosx-<wbr>x86_64/lldb.build/CustomSwift-<wbr>Release/lldb-core.build/<wbr>Script-<wbr>261EECA21337D399001D193C.sh</div><div>+ '[' CustomSwift-Release == 'CustomSwift-*' ']'</div><div>+ /usr/bin/env python $HOME/swift-4.0/<wbr>lldb/scripts/Xcode/build-llvm.<wbr>py</div><div>Traceback (most recent call last):</div><div> File "$HOME/swift-4.0/lldb/scripts/<wbr>Xcode/build-llvm.py", line 355, in <module></div><div> write_archives_txt()</div><div> File "$HOME/swift-4.0/lldb/scripts/<wbr>Xcode/build-llvm.py", line 107, in write_archives_txt</div><div> for archive in archive_list():</div><div> File "$HOME/swift-4.0/lldb/scripts/<wbr>Xcode/build-llvm.py", line 101, in archive_list</div><div> archive_lists = [collect_archives_in_path(<wbr>path) for path in paths]</div><div> File "$HOME/swift-4.0/lldb/scripts/<wbr>Xcode/build-llvm.py", line 85, in collect_archives_in_path</div><div> files = os.listdir(path)</div><div>OSError: [Errno 2] No such file or directory: '$HOME/swift-4.0/build/Ninja+<wbr>cmark-RelWithDebInfo+llvm-<wbr>RelWithDebInfo+swift-<wbr>RelWithDebInfoAssert+stdlib-<wbr>RelWithDebInfo/llvm-macosx-<wbr>x86_64/src'</div><div>Command /bin/sh failed with exit code 1</div><div><br></div><div>** BUILD FAILED **</div><div><br></div><div><br></div><div>The following build commands failed:</div><div><span style="white-space:pre-wrap">        </span>PhaseScriptExecution Build\ llvm\ and\ clang $HOME/swift-4.0/build/Ninja+<wbr>cmark-RelWithDebInfo+llvm-<wbr>RelWithDebInfo+swift-<wbr>RelWithDebInfoAssert+stdlib-<wbr>RelWithDebInfo/lldb-macosx-<wbr>x86_64/lldb.build/CustomSwift-<wbr>Release/lldb-core.build/<wbr>Script-<wbr>261EECA21337D399001D193C.sh</div><div>(1 failure)</div><div>./utils/build-script: fatal error: command terminated with a non-zero exit status 65, aborting</div><div>./utils/build-script: fatal error: command terminated with a non-zero exit status 1, aborting</div></div>