[cmake-developers] Generator expressisons in target properties

Brad King brad.king at kitware.com
Fri Oct 26 08:54:33 EDT 2012


On 10/26/2012 06:10 AM, Stephen Kelly wrote:
> The new plan would be:
> 
> * Port cmGeneratorExpression API to cmTarget
> * Add a way to determine at runtime whether linking-related information is 
> being requested at configure-time or generate-time. A property on the 
> Makefile might work.
> * Add a const char *config where appropriate to cmTarget API to pass to the 
> generator expressions.
> * Return to the depends issue and everything else.

Sounds good.  Due to things like the LOCATION properties and export()
we have long supported on-demand evaluation of things at configure
time that normally should not be needed until generate time.  Hence
the undefined behavior of setting certain properties too late.

Essentially someone needs to be able to ask at configure time
"What would this be if we generate now?".  If we had CMake to do over
again we would not allow this but it is long since too late for that.

-Brad



More information about the cmake-developers mailing list