diff options
author | Wil Stark <wil_stark@keysight.com> | 2019-01-14 21:52:25 (GMT) |
---|---|---|
committer | Wil Stark <wil_stark@keysight.com> | 2019-01-16 05:29:59 (GMT) |
commit | a541d113e606b05073810bb1b5dd5a7a8fd2eec8 (patch) | |
tree | 6834a7fb4eb0f70dad69555f209378b696b9fcdc /Tests/RunCMake/VS10Project/VsCSharpDefines.cmake | |
parent | da566d4de885130e182edc80f13691f5ca24bb61 (diff) | |
download | CMake-a541d113e606b05073810bb1b5dd5a7a8fd2eec8.zip CMake-a541d113e606b05073810bb1b5dd5a7a8fd2eec8.tar.gz CMake-a541d113e606b05073810bb1b5dd5a7a8fd2eec8.tar.bz2 |
VS: Honor target_compile_definitions for C# projects
Fixes: #18698
Diffstat (limited to 'Tests/RunCMake/VS10Project/VsCSharpDefines.cmake')
-rw-r--r-- | Tests/RunCMake/VS10Project/VsCSharpDefines.cmake | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Tests/RunCMake/VS10Project/VsCSharpDefines.cmake b/Tests/RunCMake/VS10Project/VsCSharpDefines.cmake new file mode 100644 index 0000000..62c19c5 --- /dev/null +++ b/Tests/RunCMake/VS10Project/VsCSharpDefines.cmake @@ -0,0 +1,18 @@ +enable_language(CSharp) + +add_library(foo SHARED + foo.cs) + +set_target_properties(foo PROPERTIES + LINKER_LANGUAGE CSharp) + + +# Issue 18698 +target_compile_definitions( + foo + PUBLIC + MY_FOO_DEFINE + "MY_BAR_ASSIGNMENT=bar" + $<$<CONFIG:Debug>:DEFINE_ONLY_FOR_DEBUG> + $<$<CONFIG:Release>:DEFINE_ONLY_FOR_RELEASE> +) |