[CMake] CPack integration

Dennis Schridde devurandom at gmx.net
Mon Aug 2 03:58:02 EDT 2010


On Monday 02 August 2010 04:03:09 David Cole wrote:
> On Sun, Aug 1, 2010 at
6:17 PM, Eric Noulard <eric.noulard at gmail.com> wrote:
>>> [...]
> > My
personal point of view with your idea is that
> > since we most most
probably want to maintain backward compatibility
> > it would even be better
if we can do
> > 
> > 1 - set(CPACK_...
> > 2 - include(CPack)
> > 3 -
set(CPACK_...)
> > 4 - cpack_update_config() or cpack_reconfig()
> > 
> >
that way 1, 3 and 4 are optional just as today.
> > 3 and 4 would bring what
you suggest.
> 
> You can already do this today with:
> 
> 1 -
set(CPACK_...
> 2 - include(CPack)
> 3 - set(CPACK_...)
> 4 -
include(CPack)
I tried something similar to this:
# include(CPack)
#
set(CPACK_...)
# include(CPack)
It did not work as expected.

It seems that
when including CPack the 2nd time, things like the version number are not
updated to the new values, probably because the variable is already set and
will not be automatically overwritten.

I assume that you'll suggest "set
the version number before first including CPack". And I will disagree there.
People would have to look at the sourcecode to figure out which values they
have to set before the first inclusion and which to set afterwards. From a
usability point of view this would be bad.

Kind regards,
Dennis
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://www.cmake.org/pipermail/cmake/attachments/20100802/c1062472/attachment.pgp>


More information about the CMake mailing list