Boost logo

Boost :

Subject: Re: [boost] [EXTERNAL] Request for a "Policy Review" regarding 'CMakeLists.txt'
From: Gavin Lambert (gavinl_at_[hidden])
Date: 2016-05-23 03:26:05


On 20/05/2016 22:51, Paul Fultz II wrote:
> cget doesn’t do any magic. As it says in the readme, it just runs
> the equivalent of these commands on a package:
>
> mkdir build
> cd build
> cmake ..
> cmake --build .
> cmake --build . --target install
>
> This is what people already do to build and install something from cmake.

That's not going to work very well for a Boost library anyway, since
they already contain a build subdirectory that is not intended to be an
output directory. So the usual cmake trick of deleting the build
directory to clean things will break the library.

On the other hand, if you found the "root" CMakeLists.txt in build/ or
in cmake/ first, and then run the above commands from that directory,
then they would work as expected.

This suggests that putting the CMakeLists.txt in the root of the Boost
library is not a good idea. Or that using "build" as the output
directory name is not a good idea. Or both.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk