diff options
author | Michael Stürmer <michael.stuermer@schaeffler.com> | 2017-03-07 10:40:31 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2017-03-07 14:30:27 (GMT) |
commit | bd8b5401cfb2088d5e5494d04236eda36278da8b (patch) | |
tree | 8a7d9617c0db188296a02556a26b037b4c8b864d /Source/cmGlobalVisualStudioGenerator.cxx | |
parent | e1adec32b8325fb731da084e99acd6070f5e39bf (diff) | |
download | CMake-bd8b5401cfb2088d5e5494d04236eda36278da8b.zip CMake-bd8b5401cfb2088d5e5494d04236eda36278da8b.tar.gz CMake-bd8b5401cfb2088d5e5494d04236eda36278da8b.tar.bz2 |
VS: Do not treat custom targets as CSharp targets
Fixes: #16697
Diffstat (limited to 'Source/cmGlobalVisualStudioGenerator.cxx')
-rw-r--r-- | Source/cmGlobalVisualStudioGenerator.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/cmGlobalVisualStudioGenerator.cxx b/Source/cmGlobalVisualStudioGenerator.cxx index cc2536c..ced0c26 100644 --- a/Source/cmGlobalVisualStudioGenerator.cxx +++ b/Source/cmGlobalVisualStudioGenerator.cxx @@ -750,6 +750,10 @@ bool cmGlobalVisualStudioGenerator::TargetIsCSharpOnly( if (!gt->GetConfigCommonSourceFiles(sources)) { return false; } + // Only "real" targets are allowed to be C# targets. + if (gt->Target->GetType() > cmStateEnums::OBJECT_LIBRARY) { + return false; + } } gt->GetLanguages(languages, ""); if (languages.size() == 1) { |