[CMake] generate multiple packages the easiest way
AKHRES Nader
nader.akhres at laposte.net
Sat Feb 27 11:30:34 EST 2010
Maybe I'm not very clear there.
Here is the picture (I've got two files here):
cmake "nightly build maker" script (I use cmake scripting ability
instead of .sh+.bat to avoid maintenaing os specific stuff, so this
script is just a command script):
[
SET(CPACK_GENERATOR_TXT "ZIP\;NSIS") #just escape ; so that it still a
string
launch external process which is: "cmake -DCPACK_GENERATOR=${CPACK_GENERATOR_TXT} ... -P cmake_build_script.txt "
]
and
cmake_build_script.txt
[
SET(CPACK_GENERATOR ${CPACK_GENERATOR_TXT}) #here it becomes a list
normal cmake syntax to generate projects file...
]
Le 27/02/2010 17:12, Eric Noulard a écrit :
> 2010/2/27 AKHRES Nader<nader.akhres at laposte.net>:
>
>> ok, I manage to find another way:
>>
>> I do this
>> SET(CPACK_GENERATOR_TXT "ZIP\;NSIS") #just escape ; so that it still a
>> string
>> SET(CPACK_GENERATOR ${CPACK_GENERATOR_TXT}) #here it becomes a list
>>
>> then I use -DCPACK_GENERATOR=${CPACK_GENERATOR_TXT}
>> and it works fine!
>>
> I do not understand why you need that if you already use a CMake script which
> defines CPACK_GENERATOR_TXT ???
>
>
>> Thank you Eric for you quick help, without you I would have seached in the
>> wrong way!
>>
> No problem but I'm not sure that your final solution is the easiest way to go,
> I'm missing the piece of example which explain why you need the two step
> definition...
>
>
>
More information about the CMake
mailing list