Use CACHE variable for other common CMAKE variable 35/15135/3
authorRomain Forlot <romain.forlot@iot.bzh>
Mon, 9 Jul 2018 11:57:28 +0000 (13:57 +0200)
committerRomain Forlot <romain.forlot@iot.bzh>
Mon, 9 Jul 2018 15:03:19 +0000 (17:03 +0200)
commit1ec753146fa7b2fe7187765fd51e167db4bee3c9
tree431adbb274d06752c433b7f870db5b0694366c01
parent08803561c89dd761a26e6a236829c5141056c969
Use CACHE variable for other common CMAKE variable

This is done to be able to overwite from CLI those variables.
CMAKE_INSTALL_PREFIX is a special case since it is set by default
to '/usr/local' at CMake invocation. So overwriting by CLI is fine
but set it up using config.cmake file not. So since CMake v3.7 there
is a variable to know if this variable has been set by default or not.

Change-Id: I60c5161fa9a4134d100ef709d0966d599871ad44
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
cmake/cmake.d/03-macros.cmake
cmake/common.cmake
samples.d/config.cmake.sample