From a209b31d0d088de40ba5bebdc6c9650f0583b2a6 Mon Sep 17 00:00:00 2001 From: Justin Goshi Date: Wed, 11 Sep 2019 10:28:38 -0700 Subject: cmComputeLinkInformation: Add AppendValues with backtraces --- Source/cmComputeLinkInformation.cxx | 13 +++++++++++++ Source/cmComputeLinkInformation.h | 3 +++ 2 files changed, 16 insertions(+) diff --git a/Source/cmComputeLinkInformation.cxx b/Source/cmComputeLinkInformation.cxx index dd8d246..ed0bb85 100644 --- a/Source/cmComputeLinkInformation.cxx +++ b/Source/cmComputeLinkInformation.cxx @@ -6,6 +6,7 @@ #include "cmComputeLinkDepends.h" #include "cmGeneratorTarget.h" #include "cmGlobalGenerator.h" +#include "cmListFileCache.h" #include "cmLocalGenerator.h" #include "cmMakefile.h" #include "cmMessageType.h" @@ -406,6 +407,18 @@ cmComputeLinkInformation::~cmComputeLinkInformation() delete this->OrderDependentRPath; } +void cmComputeLinkInformation::AppendValues( + std::string& result, std::vector>& values) +{ + for (BT& p : values) { + if (result.empty()) { + result.append(" "); + } + + result.append(p.Value); + } +} + cmComputeLinkInformation::ItemVector const& cmComputeLinkInformation::GetItems() const { diff --git a/Source/cmComputeLinkInformation.h b/Source/cmComputeLinkInformation.h index 0f71381..ee36a71 100644 --- a/Source/cmComputeLinkInformation.h +++ b/Source/cmComputeLinkInformation.h @@ -17,6 +17,8 @@ class cmGlobalGenerator; class cmMakefile; class cmOrderDirectories; class cmake; +template +class BT; /** \class cmComputeLinkInformation * \brief Compute link information for a target in one configuration. @@ -43,6 +45,7 @@ public: cmGeneratorTarget const* Target = nullptr; }; using ItemVector = std::vector; + void AppendValues(std::string& result, std::vector>& values); ItemVector const& GetItems() const; std::vector const& GetDirectories() const; std::vector const& GetDepends() const; -- cgit v0.12