<div dir="ltr"><div><div>Hello,<br><br></div><div>TL; DR at the end of this mail<br><br></div>I discovered build2 on <a href="http://reddit.com/r/cpp" target="_blank">reddit.com/r/cpp</a>, thanks to the multiple presentations that were done there. I wanted to give it a try. While doing the installation I watched the conferences of Boris Kolpackov and I must admit I was really impressed. I assume that I'm talking to him for the rest of this mail, since he seems to be the main developer of build2.<br><br></div>I think I should report some of the issues I encountered when trying build2 for the first time, because I think it's stupid to make potential users leave due to a bad first experience.<br clear="all"><div><div><div><br></div><div>My use-case was: I wanted to create a new project from scratch, initially without any dependency, in a single main.cpp file. Dependencies and modularization (multiples .hpp and .cpp) will come later. I am already experienced with c++. I was expecting and extremely easy set-up.While watching your conferences on youtube, it looked very easy and straightforward. However when trying to do it on my computer it was much harder than expected. Let me explain.<br><br></div><div>Installing build2 from source was easy. However when I tried to search how to do an "hello word" in the documentation, it was much harder than expected.<br><br>If you look at <a href="https://build2.org/" target="_blank">https://build2.org/</a>, their is a nice example of bpkg. But from what I understood of your conferences, I'm not going to use `bpkg`, but `b` directly. At the bottom of the pag, their is a link to <a href="https://build2.org/build2-toolchain/doc/build2-toolchain-intro.xhtml" target="_blank">https://build2.org/build2-<wbr>toolchain/doc/build2-<wbr>toolchain-intro.xhtml</a> with once again a nice use example of bpkg. I like them because if someone need to use my project (build with the build2 build system), it should be easy to understand how to build it.<br><br></div><div>So I manually search the build system manual (<a href="https://build2.org/build2/doc/build2-build-system-manual.xhtml" target="_blank">https://build2.org/build2/<wbr>doc/build2-build-system-<wbr>manual.xhtml</a>) – and BTW, you should add a link on all pages to the home of your website to make the navigation much easier.<br><br></div><div>I didn't found any references to `b create` in the manual, and I think it's missing. Furthermore, the content of the generated text file are not ideal. Some minimal examples and default value (maybe commented) should be put in them. I come back to this point in a minute. Anyway, I tried `b init` (like `git init`) without success (I think you should add an alias), then tried `b create`.<br><br></div><div>Then I tried created `main.cpp` at the root of my new directory, next to `buildfile`.<br>```<br></div><div>$ b <br>info: dir{./} is up to date<br>```<br></div><div>This was **extremely** disturbing. Hopefully I saw the conferences, and I remembered that you presented how to do it (<a href="https://www.youtube.com/watch?v=hHRaZy1LZPA">https://www.youtube.com/watch?v=hHRaZy1LZPA</a> – CppCon 2016: Boris Kolpackov “Using build2, C++ Build Toolchain" at 32:00 to be exact). Then I literally copy pasted every command to understand why my file was not compiled.<br></div><div><br>It turned out I didn't wrote:<br>```buildfile<br>exe{main}: {cxx hxx}{**}<br>```<br></div><div>``` root.build<br></div><div>using cxx<br></div><div>hxx{*}: extension = hpp<br>
cxx{*}: extension = cpp

<br>```<br></div><div>As you said multiple time in your conferences, you don't want to write magic incantations, but to be honest, and even if their isn't a lot of them, they look like magic incantations if you don't have a proper tutorial. After 2 hours it start to become evident, be you should document them.<br><br></div><div>Then I did some tests, and wanted to move the destination directory of my binary to `bin`. No big deal, I quickly understood that I had to write `exe{bin/hello}: {cxx hxx}{**}`. However I forgot to create the `bin` directory. `b` got a coredump. No big deal, it's still an early project, and it's a nice opportunity to create a bug-report, take contact with the team, and maybe write a patch. But first I would like to check with the latest source of `b` if the issue still exist. So I downloaded the source. Unfortunately, I can't use my current version of `b`, since it require the version 0.7 or later. Once again, it's fine, it's not the definitive version of build2. However, I don't understand why libpkgconf and libbutl aren't submodules. It would make the installation process from source much easier imho.<br><br><br>-------------------------------------------------------------------<br><br></div><div>TL; DR: <br><br></div><div>I wanted to try build2, but it was more complicated than expected. I would like that this project succeed, hence this mail, and I kindly suggest the following items:<br><br>
<div>- On any page of <a href="https://build2.org">https://build2.org</a>, add a link to the homepage to make the navigation easier<br></div><div>-
 Maybe add a link to 
<a href="https://build2.org/build2/doc/build2-build-system-manual.xhtml">https://build2.org/build2/doc/build2-build-system-manual.xhtml</a> in the 
homepage or in the toolchain introduction</div>

<br></div><div>- In the preface of <a href="https://build2.org/build2/doc/build2-build-system-manual.xhtml">https://build2.org/build2/doc/build2-build-system-manual.xhtml</a>, describe exactly the commands used in <a href="https://www.youtube.com/watch?v=hHRaZy1LZPA">https://www.youtube.com/watch?v=hHRaZy1LZPA</a> at 32:00 (CppCon 2016: Boris Kolpackov “Using build2, C++ Build Toolchain")<br></div><div>- Ideally, `b create` should generate them, so you would just have to write `mkdir hello && cd hello && b create && edit hello.cpp && b` in the preface.<br>- Add and alias `init` to `create` for `b` (just like git)<br><br></div><div>- Add 
libpkgconf, and 
libbutl as submodules of build2.<br><br></div><div>Thanks for your time.<br></div><div>Most of those items are really easy to fix, but should make a much better experience for new users. I wish you a lot of new users.<br><br></div><div>Sincerely,<br></div><div>Robin.<br></div><div><br></div><div>-- <br><div class="gmail-m_72540255413986722gmail_signature">Robin</div>
</div></div></div></div>