[cmake-developers] conditionals in generator expressions
Stephen Kelly
steveire at gmail.com
Mon Sep 17 08:55:41 EDT 2012
Stephen Kelly wrote:
>>> The next thing I want to do is to see if I can make full use of
>>> cmGeneratorTarget and use const proactively while doing so, to make the
>>> code more clear. I'm not 100% certain that's possible, but it's the next
>>> goal I have. Any comments on that?
>>
>> That would be a really great example of splitting configure-time
>> constructs from generate-time constructs.
>
> Right. I investigated a little bit already and it seems there's at least
> some low-hanging fruit.
I've put my work on the use-generator-target branch in my clone.
Using const as proactively as I wanted is not really possible/worth it
because of all the memoizing cmake does, but I've ported it to use
cmGeneratorTarget enough to be able to add a
cmGeneratorTarget::GetCompileDefinitions(const char *config)
and use generator expressions in the implementation, and to use generator
expressions in
cmGeneratorTarget::GetIncludeDirectories(const char *config)
too. That should be three trivial patches, but I haven't written them yet.
That's all I'm aiming for of the target_use_targets feature for the next
release, so I think that's still on track.
Thanks,
Steve.
More information about the cmake-developers
mailing list