diff options
author | Brad King <brad.king@kitware.com> | 2023-10-18 13:51:43 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2023-10-18 13:51:52 (GMT) |
commit | dc7bed55e6f570ba1d64b48d5e6e1cf2f16bfaa0 (patch) | |
tree | 07bed4427314859ebc9b838414e82df37e6daff4 /Source | |
parent | c924b9e9f7cba45e3ba80357341aab97aa28dc1e (diff) | |
parent | 17fd7fe2aed20357275918591544b292d86f0fe1 (diff) | |
download | CMake-dc7bed55e6f570ba1d64b48d5e6e1cf2f16bfaa0.zip CMake-dc7bed55e6f570ba1d64b48d5e6e1cf2f16bfaa0.tar.gz CMake-dc7bed55e6f570ba1d64b48d5e6e1cf2f16bfaa0.tar.bz2 |
Merge topic 'cxxmodules-vs-no-synthetic-targets' into release-3.28
17fd7fe2ae Tests/CXXModules: test Visual Studio synthetic target error
badb6ab120 VS: Explicitly disallow C++ modules provided by imported targets
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8895
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmVisualStudio10TargetGenerator.cxx | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx index ce94fe1..4860d9a 100644 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@ -358,6 +358,15 @@ std::ostream& cmVisualStudio10TargetGenerator::Elem::WriteString( void cmVisualStudio10TargetGenerator::Generate() { + if (this->GeneratorTarget->IsSynthetic()) { + this->GeneratorTarget->Makefile->IssueMessage( + MessageType::FATAL_ERROR, + cmStrCat("Target \"", this->GeneratorTarget->GetName(), + "\" contains C++ modules intended for BMI-only compilation. " + "This is not yet supported by the Visual Studio generator.")); + return; + } + for (std::string const& config : this->Configurations) { this->GeneratorTarget->CheckCxxModuleStatus(config); } |