summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/cmTarget.cxx11
-rw-r--r--Source/cmTarget.h3
2 files changed, 14 insertions, 0 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index ae250d4..18a7c50 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -866,6 +866,17 @@ cmListFileBacktrace const& cmTarget::GetBacktrace() const
}
//----------------------------------------------------------------------------
+std::string cmTarget::GetSupportDirectory() const
+{
+ std::string dir = this->Makefile->GetCurrentOutputDirectory();
+ dir += cmake::GetCMakeFilesDirectory();
+ dir += "/";
+ dir += this->Name;
+ dir += ".dir";
+ return dir;
+}
+
+//----------------------------------------------------------------------------
bool cmTarget::IsExecutableWithExports()
{
return (this->GetType() == cmTarget::EXECUTABLE &&
diff --git a/Source/cmTarget.h b/Source/cmTarget.h
index dce4feb..23ef9dc 100644
--- a/Source/cmTarget.h
+++ b/Source/cmTarget.h
@@ -415,6 +415,9 @@ public:
/** Get a backtrace from the creation of the target. */
cmListFileBacktrace const& GetBacktrace() const;
+ /** Get a build-tree directory in which to place target support files. */
+ std::string GetSupportDirectory() const;
+
private:
/**
* A list of direct dependencies. Use in conjunction with DependencyMap.