[cmake-developers] multiconfig cpack

Eric Noulard eric.noulard at gmail.com
Thu Jan 26 03:41:57 EST 2012


2012/1/26 Clinton Stimpson <clinton at elemtech.com>:
>
> On Jan 25, 2012, at 3:54 PM, Clinton Stimpson wrote:
>
>>
>> Being able to package both a debug and release build into one package using
>> cpack has come up on the mailing list a couple times.  It seems the only
>> workable solution is to have two makefile builds with a single cpack config that
>> points to both.
>>
>> However, I'm wondering, in the case of mutli-config generators, if it would be
>> acceptable to modify cpack to take multiple configurations as
>> cpack -C Debug;Release .
>>
>> and modify the main loop in
>> cmCPackGenerator::InstallProjectViaInstallCMakeProjects to also loop over
>> build types.
>>
>> With that, the cpack config file can stay in the one build tree, which is the
>> typical use case.
>>
>
> Umm.. never mind.  I'd prefer going with a more portable solution and can probably add a flag to create the secondary build tree, and configure the main build tree's CPackConfig file to include the secondary one.

Hi Clint,

Portability goal is indeed good.
I think that "multi-config" cpack (several config processed in a
single cpack run)
and/or multi-projects cpack (several projects packaged together)
see e.g: http://public.kitware.com/Bug/view.php?id=11808
is interesting for many of us.

Note that I'd rather say
"several XX processed in a single cpack run"  (XX = config==build tree
or project)
than
"several XX processed in a single package"

because you may want to process Debug and Optimize config together but
still get componentized packaging with may be several packages.

I think there are several interesting ideas about "using cpack several
times" in here:
http://public.kitware.com/Bug/view.php?id=10751
http://www.cmake.org/pipermail/cmake/2010-August/038678.html

It may not seems obvious why mulitple CPack processing is linked to
"multi-config"
but I think Clint would get my point, if not I'll try to elaborate.


-- 
Erk
Membre de l'April - « promouvoir et défendre le logiciel libre » -
http://www.april.org



More information about the cmake-developers mailing list