[cmake-developers] module proposal: PreventInSourceBuilds

Roger Leigh rleigh at codelibre.net
Fri Nov 9 06:44:36 EST 2018


On 09/11/2018 10:34, Joachim Wuttke wrote:
> In all my projects, the top-level CMakeLists.txt contains the line
> 
> include(PreventInSourceBuilds)
> 
> to protect users (and myself) from unintentionally running CMake
> in the source directory.

I for one have an equivalent to this logic in all my projects to prevent 
in-source builds.  Having a standardised version would be very useful, 
and I would certainly make use of it.


Thanks,
Roger


More information about the cmake-developers mailing list