[cmake-developers] [CMake] 2.8.11-rc3 generator expression error

Stephen Kelly steveire at gmail.com
Thu May 2 02:46:12 EDT 2013


Brad King wrote:

> On 04/30/2013 07:38 PM, Stephen Kelly wrote:
>> Brad King wrote:
>>> Reading the commit messages and code in more detail, it looks wrong
>>> to have CachedLinkInterfaceIncludeDirectoriesEntries not per-config.
>>> It looks like the generated value can be different per-config and
>>> currently it accumulates cached values across multiple configs.
>> 
>> Yes, that's probably a more-accurate description.
> 
> I'm saying that even after the current version of the topic the
> caching is still accumulating across configurations in multi-config
> generators.  AFAICT that part is not yet fixed.  The
> CachedLinkInterfaceIncludeDirectoriesEntries needs to map from config
> to list of entries.

Hmm, I don't think that is true currently. Have you tried producing buggy 
code for the issue?

The CachedLinkInterfaceIncludeDirectoriesEntries is a vector of 
IncludeDirectoriesEntry*, which contains the TargetName (doesn't change per-
config), a cmCompiledGeneratorExpression (doesn't change per config), and a 
vector of cached includes. That includes cache is only populated if the 
includes are config-independent.

I'm not sure if storing a map of config to IncludeDirectoriesEntry* instead 
would have an advantage. Probably only in projects with a large number of 
config-sensitive include directories.

Thanks,

Steve.





More information about the cmake-developers mailing list