summaryrefslogtreecommitdiffstats
path: root/Source/cmComputeLinkInformation.h
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2023-11-18 04:04:35 (GMT)
committerBrad King <brad.king@kitware.com>2023-11-23 19:26:31 (GMT)
commit1175f1c874a7cd34d643902bc428df92bce3471a (patch)
tree58011c63b67ff637e27fe212e1447a9116f0288c /Source/cmComputeLinkInformation.h
parentd2fa56772f290c61925a70161c77be5f4334fd77 (diff)
downloadCMake-1175f1c874a7cd34d643902bc428df92bce3471a.zip
CMake-1175f1c874a7cd34d643902bc428df92bce3471a.tar.gz
CMake-1175f1c874a7cd34d643902bc428df92bce3471a.tar.bz2
LinkItem: track `cmSourceFile` instances for external objects
The target may be required in order to provide Fortran modules, so track the source file so that the target may be looked up when needed.
Diffstat (limited to 'Source/cmComputeLinkInformation.h')
-rw-r--r--Source/cmComputeLinkInformation.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/cmComputeLinkInformation.h b/Source/cmComputeLinkInformation.h
index 1e8556d..3ee995f 100644
--- a/Source/cmComputeLinkInformation.h
+++ b/Source/cmComputeLinkInformation.h
@@ -22,6 +22,7 @@ class cmGeneratorTarget;
class cmGlobalGenerator;
class cmMakefile;
class cmOrderDirectories;
+class cmSourceFile;
class cmake;
/** \class cmComputeLinkInformation
@@ -51,16 +52,21 @@ public:
{
Item(BT<std::string> v, ItemIsPath isPath,
cmGeneratorTarget const* target = nullptr,
+ cmSourceFile const* objectSource = nullptr,
FeatureDescriptor const* feature = nullptr)
: Value(std::move(v))
, IsPath(isPath)
, Target(target)
+ , ObjectSource(objectSource)
, Feature(feature)
{
}
BT<std::string> Value;
ItemIsPath IsPath = ItemIsPath::No;
cmGeneratorTarget const* Target = nullptr;
+ // The source file representing the external object (used when linking
+ // `$<TARGET_OBJECTS>`)
+ cmSourceFile const* ObjectSource = nullptr;
bool HasFeature() const { return this->Feature != nullptr; }
const std::string& GetFeatureName() const