[CMake] --enable-* with cmake

Brandon Van Every bvanevery at gmail.com
Fri Aug 10 12:14:55 EDT 2007


On 8/10/07, Eric Noulard <eric.noulard at gmail.com> wrote:
>
> I think I perfectly understand your point but I would
> say that adding "pre-parsing" phase where
> The main CMakeLists.txt "pre-parsed" in order to list
> the OPTION and their desc statement would indeed be feasible
>
> cmake -p would show INCONDITIONAL OPTION
> cmake -p -v may show ALL OPTION flagging those which
> may not be "resolved" without running CMake.

We're getting into the realm of philosophy here.  Do we want to
condition the user to have an incessant need to know all the options
available, whether or not they are appropriate or will help him?  Or
do we want to condition him to accept the information hiding
mechanisms that CMake employs?  I think the latter.

It might be reasonable, however, to show OPTIONS resolved at the
current scope.  And to note whether conditional options exist, i.e.
"Warning: conditional options detected.  You are advised to run
(CMakeSetup|CCMake) and resolve them iteravely."  Or the opposite:
"All options have been resolved."

Is it possible to resolve them iteravely from the command line?  I've
had no reason to try that, but in principle, could you hammer the
cache over and over again until it worked?  You'd need feedback to
know what the conditional options are.  Is there any mechanism to do
that at present, or do we need the OPTIONS readout as suggested above?


Cheers,
Brandon Van Every


More information about the CMake mailing list