[CMake] Don't list Up-to-date files during install

2019-10-24 Thread Jason Beach
When installing files, cmakes prints a list of all files that are to be installed, even if some of those files are already installed and up-to-date (i.e. installed from a previous build). If the file is not installed or out-of date, cmake prints "Installing: ..." and if a file was already installe

[CMake] add_subdirectory namespaces

2019-07-24 Thread Jason Beach
I've been reorganizing / updating our software cmake build. It currently uses a mixture of Externa Projects and normal target definitions that depend on the external projects (which has you probably know causes much sorrow and grief). One of my goals in the reorganization was to replace all the Ex

[CMake] FetchContent or Export Targets

2019-03-23 Thread Jason Beach
Hi, As I've been learning CMake, it seems the best practice for a library is for it to export the targets it creates. There is also the relatively new command FetchContent. It seems that at least in part the FetchContent command obviates the need for exporting targets. I can see that for larger

[CMake] Passing CMake Arguments to FetchContent

2019-03-22 Thread Jason Beach
I'm upgrading from cmake 3.5.1 and am trying to understand the new FetchContent command. So far I have: cmake_minimum_required(VERSION 3.14) project (json_test) include(FetchContent) set(JSON_BuildTests OFF) #if I try this I get a warning as it appears to be deprecated FetchContent_Declare(