[CMake] CMake 3.0-rc1 now ready for testing!
Hendrk Sattler
post at hendrik-sattler.de
Mon Mar 3 04:21:34 EST 2014
Am 2014-02-28 20:28, schrieb Robert Maynard:
> * The "COMPILE_DEFINITIONS_<CONFIG>" directory properties and the
> "COMPILE_DEFINITIONS_<CONFIG>" target properties have been
> deprecated. Instead set the corresponding "COMPILE_DEFINITIONS"
> directory property or "COMPILE_DEFINITIONS" target property and use
> "generator expressions" like "$<CONFIG:...>" to specify per-
> configuration definitions. See policy "CMP0043".
Some notes about this policy:
1. It warns for targets where a something like this was done:
set_property ( DIRECTORY . APPEND PROPERTY
COMPILE_DEFINITIONS_DEBUG TEST_ON )
-> Maybe warn just once for the direct appearance of this?
2. The CMP0043 descriptions only mentions target specific solutions.
3. I never liked the set_property ( DIRECTORY... ) solution because
there is also
and add_definitions() command. In the description of
add_definitions(), it is
mentioned:
"Arguments to add_definitions may use “generator expressions” with
the syntax “$<...>”."
However, I tried and this results in broken MSVC10 project files as
those then contain:
<AdditionalOptions> ""$"<"$"<CONFIG:Debug>:-DTEST_ON>"
%(AdditionalOptions)</AdditionalOptions>
Regards,
HS
More information about the CMake
mailing list