mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-06 05:40:54 -06:00
cmTarget: Add HasKnownObjectFileLocation() shorthand
Allow `cmGlobalGenerator`s to decide `HasKnownObjectFileLocation()` per given `cmTarget` - `cmGlobalGenerator::HasKnownObjectFileLocation()` now takes an optional `cmGeneratorTarget` - `cmTarget::HasKnownObjectFileLocation()` added as a shorthand
This commit is contained in:
@@ -195,7 +195,7 @@ cmStateEnums::TargetType cmExportBuildFileGenerator::GetExportTargetType(
|
||||
// to support transitive usage requirements on other targets that
|
||||
// use the object library.
|
||||
if (targetType == cmStateEnums::OBJECT_LIBRARY &&
|
||||
!this->LG->GetGlobalGenerator()->HasKnownObjectFileLocation(nullptr)) {
|
||||
!target->Target->HasKnownObjectFileLocation(nullptr)) {
|
||||
targetType = cmStateEnums::INTERFACE_LIBRARY;
|
||||
}
|
||||
return targetType;
|
||||
|
||||
Reference in New Issue
Block a user