summaryrefslogtreecommitdiffstats
path: root/Source/cmGeneratorTarget.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2023-12-05 20:47:17 (GMT)
committerBrad King <brad.king@kitware.com>2023-12-05 20:48:36 (GMT)
commit03d86f9d9ce0d55ac297ea876245f0e5ac539cd0 (patch)
treefdde80842f22e60a593963f7e63b52f43ff56a02 /Source/cmGeneratorTarget.cxx
parent3e8f0211378664665abc5e09503296eb4825b50a (diff)
downloadCMake-03d86f9d9ce0d55ac297ea876245f0e5ac539cd0.zip
CMake-03d86f9d9ce0d55ac297ea876245f0e5ac539cd0.tar.gz
CMake-03d86f9d9ce0d55ac297ea876245f0e5ac539cd0.tar.bz2
cmGeneratorTarget: Add helper to check for known runtime artifact
Diffstat (limited to 'Source/cmGeneratorTarget.cxx')
-rw-r--r--Source/cmGeneratorTarget.cxx13
1 files changed, 13 insertions, 0 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index 4b4d8b9..45073f7 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -1258,6 +1258,19 @@ bool cmGeneratorTarget::CanCompileSources() const
return this->Target->CanCompileSources();
}
+bool cmGeneratorTarget::HasKnownRuntimeArtifactLocation(
+ std::string const& config) const
+{
+ if (!this->IsRuntimeBinary()) {
+ return false;
+ }
+ if (!this->IsImported()) {
+ return true;
+ }
+ ImportInfo const* info = this->GetImportInfo(config);
+ return info && !info->Location.empty();
+}
+
const std::string& cmGeneratorTarget::GetLocationForBuild() const
{
static std::string location;