James Bigler wrote:
What is it that people want beyond -DBUILD_THIS_THAT_WHATEVER:BOOL=TRUE
could provide?
Do they want: --enable-build_this_that_whatever?
People that work with embedded systems might want a stripped down
version of a library, for instance. So disabling features might be a
strong use case.
I also don't understand why we have to parse the whole CMakeLists.txt
structure. We should treat these command line args like we cache
variables like CPack does when you configure different builds.
But in the first time cmake is run, there's no cache and no way to know
what are the command line parameters. Is must run the whole build to
know that. So the first time 'cmake . --help' runs, the whole build
should be parsed and executed.
But... what if we have this extreme case?
IF("${CMAKE_BUILD_TYPE}" STREQUAL "Debug")
add_command_line_parameter(whatever)
ENDIF()
That is, the parameter is bound to another parameter? It's not
impossible to imagine a case where each time we run cmake --help, a
different set of parameters is shown. I know, that's stupid, but corner
cases usually are...
Regards,
rod
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake