[CMake] Re: General modernization facility

Brandon Van Every bvanevery at gmail.com
Tue Dec 18 20:00:19 EST 2007


On Dec 18, 2007 7:31 PM, Rodolfo Lima <rodolfo at rodsoft.org> wrote:
> Brandon Van Every escreveu:
> >> That would be easy to cope with, no version specification = 2.4.7.
> >
> > If it actually works under 2.4.7 and doesn't need some other earlier
> > version to function with.
>
> We would have to guarantee that version 2.4.7 executes correctly every
> script made up till now.

I don't see how we could.

> > What if 2.4.7 ships with an arguably bad behavior, 2.4.8 fixes it, and
> > my code is stuck with the 2.4.7 behavior because you didn't think
> > anyone was ever supposed to avail themselves of improvements?
>
> That would be a big mess, but if the script *works*, even with bad
> behavior, so be it. Maybe a warning should be emitted. The point is to
> guarantee that the script the author made will work the same way he
> intended, forever. It would be wrong if we changed the behavior the
> author relied upon.

The author may have been completely unaware of the potential of the
error condition, having never seen the circumstances in which the
error occurs.  We don't know that "I wrote this using 2.4.7" means "I
want it frozen for 2.4.7."  Let's even say, for sake of argument, that
you provided an interface for the author to state exactly that.
version_freeze(2.4.7).  It still may not be a good idea, because the
author may not have full knowledge of the consequences of his
decision.

> I think that this solution would let Kitware add disruptive features
> with ease.

I don't think we need to tie "disruptive" features to version numbers.
 I want set_property(GLOBAL PROPERTIES CMAKE_REQUIRE_BOOL TRUE).  I'm
willing to wait a loooooong time for it to become a default CMake
behavior.  I think include(Modern) is a good idea in principle, for
people who want to use a well-defined collection of forward looking
behaviors.  The idea may need refinement in practice, but the general
idea is "opt in."  Not "tie my hands."


Cheers,
Brandon Van Every


More information about the CMake mailing list