On 08/28/2013 10:29 AM, Stephen Kelly wrote:
> at least parts of KWIML should fit into this discussion too
[snip]
>> If instead projects distribute their own copies then we have
>> the option of changing the API and it is up to them to deal with it when
>> updating.
> 
> Yes. That's what I propose too.
> 
>  write_compiler_detection_header(
>    FILE ${CMAKE_CURRENT_BINARY_DIR}/grantlee_compiler_detection.h
>    PREFIX Grantlee_
>  )

Not quite.  A newer CMake would have to write a compatible header
from this command.  The current design of KWSys and KWIML is that
their source should be directly copied into the project source
(perhaps with various scripts to run updates).  We can change them
as much as we want and projects will decide when they can update.
Each version of their source only has to work with one version
of the library.  With an interface like the above many versions
of CMake would have to work with the same version of the project
source.

> Yes, versioning is a good idea to think about.
> 
>  write_compiler_detection_header(
>    FILE ${CMAKE_CURRENT_BINARY_DIR}/grantlee_compiler_detection.h
>    PREFIX Grantlee_
>    VERSION 3
>  )

This could help somewhat because we could change what is produced
by a newer version while still knowing how to generate the old
version.  The version argument must be required.

Rather than a single versioned header we should also consider
asking the caller to list the information and features needed.
That way a project can expose a header without more information
than they want to support.

-Brad
--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to