<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi Lane,<div class=""><br class=""></div><div class="">You shouldn't need to install re2c to build Ninja.</div><div class=""><br class=""></div><div class="">This looks like something is wrong in the build script. It did successfully build Ninja, but it isn't getting found by CMake for the mark build.</div><div class=""><br class=""></div><div class="">Can you open an SR for this on <a href="http://bugs.swift.org" class="">bugs.swift.org</a>?</div><div class=""><br class=""></div><div class="">If you want to debug yourself, it looks like the PATH export at utils/build-script-impl:1287 isn't working, it should have let ninja be found for the rest of the commands.</div><div class=""><br class=""></div><div class=""> - Daniel</div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Dec 4, 2015, at 11:22 AM, Lane Schwartz <<a href="mailto:dowobeha@gmail.com" class="">dowobeha@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Hi,<br class=""><br class="">First of all, congratulations on the open source release! I'm very excited!<br class=""><br class="">Second, I'm running into trouble building from source, particularly in regards to getting ninja bootstrapped. I'm on Scientific Linux. I first used yum to install packages for llvm, llvm-devel, clang, and cmake.<br class=""><br class="">I then did the following, following the README.md in the swift git repo: <br class=""><br class=""> git clone git@github.com:apple/swift.git swift<br class=""> git clone git@github.com:apple/swift-llvm.git llvm<br class=""> git clone git@github.com:apple/swift-clang.git clang<br class=""> git clone git@github.com:apple/swift-lldb.git lldb<br class=""> git clone git@github.com:apple/swift-cmark.git cmark<br class=""> git clone git@github.com:apple/swift-llbuild.git llbuild<br class=""> git clone git@github.com:apple/swift-package-manager.git swiftpm<br class=""> git clone git@github.com:apple/swift-corelibs-xctest.git<br class=""> git clone git@github.com:apple/swift-corelibs-foundation.git<br class=""><br class=""><div class=""><br class=""></div><div class="">The README.md also states:</div><div class=""><br class=""></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Ninja is the current recommended build system for building Swift and is the default configuration generated by CMake. If you're on OS X or don't install it as part of your Linux distribution, clone it next to the other projects and it will be bootstrapped automatically</blockquote><div class=""><br class=""></div><div class=""> My Linux distro doesn't package ninja, so I also did this:</div><br class="">git clone git@github.com:martine/ninja.git<div class=""><br class=""></div><div class="">I then attempted to build swift:</div><div class=""><br class=""></div>$ ./swift/utils/build-script<div class=""><br class=""></div><div class="">Which resulted in errors, and as far as I can tell did not attempt to build the ninja distro that I downloaded into the ninja directory in my current working directory:</div><div class=""><br class=""><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">which: no ninja in (/usr/lib64/qt-3.3/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/lanes/.local/bin:/home/lanes/bin)<br class="">Building the standard library for: swift-stdlib-linux-x86_64<br class="">Running Swift tests for: check-swift-linux-x86_64<br class="">+ rm -rf /home/lanes/swift/build/Ninja-DebugAssert/ninja-build<br class="">+ cp -r /home/lanes/swift/ninja /home/lanes/swift/build/Ninja-DebugAssert/ninja-build<br class="">++ uname -s<br class="">+ [[ Linux == \D\a\r\w\i\n ]]<br class="">+ cd /home/lanes/swift/build/Ninja-DebugAssert/ninja-build<br class="">+ python ./configure.py --bootstrap<br class="">bootstrapping ninja...<br class="">warning: A compatible version of re2c (>= 0.11.3) was not found; changes to src/*.<a href="http://in.cc" class="">in.cc</a> will not affect your build.<br class="">wrote build.ninja.<br class="">bootstrap complete. rebuilding...<br class="">[24/24] LINK ninja<br class="">cmark: using standard linker<br class="">+ cd /home/lanes/swift/build/Ninja-DebugAssert/cmark-linux-x86_64<br class="">+ /usr/bin/cmake -G Ninja -DCMAKE_C_COMPILER:PATH=clang -DCMAKE_CXX_COMPILER:PATH=clang++ -DCMAKE_BUILD_TYPE:STRING=Debug /home/lanes/swift/cmark<br class="">CMake Error: CMake was unable to find a build program corresponding to "Ninja". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.<br class="">CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.<br class="">Missing variable is:<br class="">CMAKE_C_COMPILER_ENV_VAR<br class="">CMake Error: Could not find cmake module file:/home/lanes/swift/build/Ninja-DebugAssert/cmark-linux-x86_64/CMakeFiles/2.8.11/CMakeCCompiler.cmake<br class="">CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.<br class="">Missing variable is:<br class="">CMAKE_CXX_COMPILER_ENV_VAR<br class="">CMake Error: Could not find cmake module file:/home/lanes/swift/build/Ninja-DebugAssert/cmark-linux-x86_64/CMakeFiles/2.8.11/CMakeCXXCompiler.cmake<br class="">-- Configuring incomplete, errors occurred!<br class="">./swift/utils/build-script: command terminated with a non-zero exit status 1, aborting</blockquote><div class=""><br class=""></div><div class=""><br class=""></div><div class="">This leads me to a couple of questions:</div><div class=""><br class=""></div><div class="">* Do I need to first build and install re2c? If so, this should perhaps be mentioned as a prereq.</div><div class="">* Is there anything differently I should be doing to get the bootstrap process running successfully?</div><div class=""><br class=""></div><div class="">Thanks,</div><div class="">Lane</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div></div></div>
<img src="https://u2002410.ct.sendgrid.net/wf/open?upn=AdkfTiApI80cNEyortTzHbERtY5det-2FDBvSxuhs4q2O5dLnG7UVIjbE29vVa3BdMe7HHE9Gv2-2BcIkVlnfIm6d2JcIswtx4TuXNSbgc7y5AXyK-2ByKjaUtDoXmv7bFu4XqMy4z-2BKbsrKSDN4iPUsH8tqceNz89k4FB2yRLkO7ERwMNYzscdBv6SMxOin4qH9r-2BkchzH0tHou5q2bS6JQPZwbwTax5qr6F4Z0CEUwkk3PQ-3D" alt="" width="1" height="1" border="0" style="height:1px !important;width:1px !important;border-width:0 !important;margin-top:0 !important;margin-bottom:0 !important;margin-right:0 !important;margin-left:0 !important;padding-top:0 !important;padding-bottom:0 !important;padding-right:0 !important;padding-left:0 !important;" class="">
_______________________________________________<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>