Boost logo

Boost :

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

On 16/05/2016 15:32, David Sankel wrote:
> We recommend and propose that the Boost Guidelines are modified to
> allow library authors, at their own discretion, to include a
> 'CMakeLists.txt' file in their library's top-level directory.

At the risk of reopening this debate (which I hope doesn't happen), here
is my interpretation of the current guidelines [1].

   1. The "real" CMakeLists.txt file should be in the build subdirectory
of the library (as this is where such files are specified to belong).
But this can include other files elsewhere in the tree, such as in src,
doc, or test, since it's common to refer to individual source files only
from a build script in the same directory.

   2. There is nothing preventing a library author from adding other
files (they are neither required nor forbidden). So another
CMakeLists.txt could be in the root, which simply includes the one in build.

So I don't think that any changes are required to the guidelines if
library authors do want to put cmake files in the root (though I've said
elsewhere that this might not be the best idea, due to directory name

I believe this was also what Rene Rivera was implying when asking for a
PR containing specific wording changes (and more explicitly in the
"Files in individual libraries" thread).


Boost list run by bdawes at, gregod at, cpdaniel at, john at