VS10 Generator always appends ;%(PreprocessorDefinitions) to <PreprocessorDefinitions> in .vcxproj file, causing C Defines to always 'inherit' the parent settings.
The current behavior essentially implements "Inherit from parent". There are use cases where this is not desirable. VS natively supports NOT inheriting the parent settings for this reason. The code that does this currently is in cmVisualStudioGeneratorOptions.cxx, line 460:
if (this->Version >= cmGlobalVisualStudioGenerator::VS10) {
oss << ";%(" << tag << ")";
}
In my particular case, the platform (parent) defines 'UNDER_CE' (A WindowsCE target), and I can't see any other way to remove this define from the generated VS solution that doesn't affect the entire MSBuild system (e.g. modifying the Toolset.props for my Windows CE SDK). It seems like a CMake property that would make this behavior (appending ;%(PreprocessorDefinitinos)) conditional could resolve this issue.