On 10/05/2016 06:38 PM, Stephen Kelly wrote: > The suggestion to use the first cmMakefile for these kinds of definitions is > a good one > > 1) It can be documented that the variable can only be set in the top level > 2) It is what people already do probably > 3) It is more convenient than the API for setting cache or global properties
That makes sense, but the codelite feature is just following a long-standing convention used for many settings. If you want to make a sweeping effort to formalize this kind of scoping then that is fine with me. Mostly I think it will be documenting that the value of the variable at the end of the top-level CMakeLists.txt file is the one that is used. In some cases that may involve fixing generators to actually use that one. -Brad -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake-developers