[CMake] CPack output name using VS IDE

Eric Noulard eric.noulard at gmail.com
Wed Jan 11 01:59:13 EST 2012


2012/1/11 Totte Karlsson <totte at dunescientific.com>:
>>>>    cmake --help-variable CMAKE_CFG_INTDIR
>>>
>>>
>>> When executing the PACKAGE target from the IDE, that variable is
>>> evaluated to
>>> $(Configuration)
>>
>>
>> Not quite. CMake evaluates it to $(Configuration) (or what ever the
>> particular IDE uses), which then gets expanded by the IDE to the current
>> configuration, i.e. Debug, Release, etc.
>
>
> In the PACKAGE target it does not seem to get expanded. Any idea how to
> 'force' such thing.

Yes it should be.
The trouble is this is not evaluated at but at CMake time when
include(CPack) is processed.

Then at CPack time the value is read from within cpack command so that
it is not evaluated either.
That's why I said:

"You may probably hand-craft you own custom_command/target for that
but  don't know how to add this to the built-in "PACKAGE" target."

I'm not using Visual Studio on a daily basis and I cannot test the scheme right
now but may be other can.

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


More information about the CMake mailing list