That Crazy Carl Guy That Crazy Carl Guy - 4 months ago 24
Git Question

Using Modular Boost from GitHub

I'm a little new to Git, but I've cloned and used a few other repositories before. I've read the documentation on how to clone Boost's git repository, and I know it's more complicated than a normal repository.

Step 1, clone the repository:

git clone "https://github.com/boostorg/build.git" Boost


Step 2, install the module/modules you want to build.

cd Boost
git submodule update --init


As far as I know, that should download all modules to the folder Boost/lib, but I don't even have a folder called Boost/lib. I didn't even get an error message.

With that, I'm also wondering how to download specifically the modules I want to use, like boost::filesystem for example.

Answer

There is a super-project that you need to clone and work from that has (almost) all the current Boost sub-repos linked into it (Boost super-project). You can find further information on how to work in that clone at the wiki. The commands you invoke should look something like this (for non-Windows systems):

git clone --recursive "https://github.com/boostorg/boost.git" modular-boost
cd modular-boost
./bootstrap.sh
./b2 headers

But if you just want to get the bleeding edge and deal with git, you can also download snapshot archives from SourceForge for the master and develop branches.