summaryrefslogtreecommitdiff
path: root/Source/cmGeneratorTarget.cxx
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2023-01-31 22:46:48 -0500
committerBen Boeckel <ben.boeckel@kitware.com>2023-02-08 13:00:45 -0500
commit4b38d7d100144b51ab1852413213716ffb9678bb (patch)
tree3719b658063c25c9807677551095d8b535df86bc /Source/cmGeneratorTarget.cxx
parent8c61f15cdc0cfb706391ee354482555f1bc08232 (diff)
downloadcmake-4b38d7d100144b51ab1852413213716ffb9678bb.tar.gz
cmGeneratorTarget: `INTERFACE` targets with C++ modules are also "in"
`INTERFACE` targets with C++ modules are basically BMI-only modules. It is unknown if they will be useful directly (due to ODR of the `module M;` initializers needing to live in some specific object file). However, they will be used to attach BMI-only compilations of `IMPORTED` C++ modules.
Diffstat (limited to 'Source/cmGeneratorTarget.cxx')
-rw-r--r--Source/cmGeneratorTarget.cxx8
1 files changed, 5 insertions, 3 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index 5e352b2957..f83be264e8 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -1222,10 +1222,12 @@ bool cmGeneratorTarget::IsInBuildSystem() const
case cmStateEnums::GLOBAL_TARGET:
return true;
case cmStateEnums::INTERFACE_LIBRARY:
- // An INTERFACE library is in the build system if it has SOURCES or
- // HEADER_SETS.
+ // An INTERFACE library is in the build system if it has SOURCES,
+ // HEADER_SETS, or C++ module filesets.
if (!this->SourceEntries.empty() ||
- !this->Target->GetHeaderSetsEntries().empty()) {
+ !this->Target->GetHeaderSetsEntries().empty() ||
+ !this->Target->GetCxxModuleSetsEntries().empty() ||
+ !this->Target->GetCxxModuleHeaderSetsEntries().empty()) {
return true;
}
break;