summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
Diffstat (limited to 'Source')
-rw-r--r--Source/cmExportFileGenerator.cxx5
-rw-r--r--Source/cmExportFileGenerator.h3
-rw-r--r--Source/cmExportInstallFileGenerator.cxx3
-rw-r--r--Source/cmInstallCommand.cxx2
-rw-r--r--Source/cmTarget.cxx16
-rw-r--r--Source/cmTarget.h7
6 files changed, 23 insertions, 13 deletions
diff --git a/Source/cmExportFileGenerator.cxx b/Source/cmExportFileGenerator.cxx
index 2d80f0e..b46b933 100644
--- a/Source/cmExportFileGenerator.cxx
+++ b/Source/cmExportFileGenerator.cxx
@@ -375,7 +375,8 @@ void cmExportFileGenerator::PopulateSourcesInterface(
void cmExportFileGenerator::PopulateIncludeDirectoriesInterface(
cmGeneratorTarget const* target,
cmGeneratorExpression::PreprocessContext preprocessRule,
- ImportPropertyMap& properties, std::vector<std::string>& missingTargets)
+ ImportPropertyMap& properties, std::vector<std::string>& missingTargets,
+ cmTargetExport const& te)
{
assert(preprocessRule == cmGeneratorExpression::InstallInterface);
@@ -385,7 +386,7 @@ void cmExportFileGenerator::PopulateIncludeDirectoriesInterface(
cmGeneratorExpression ge;
std::string dirs = cmGeneratorExpression::Preprocess(
- cmJoin(target->Target->GetInstallIncludeDirectoriesEntries(), ";"),
+ cmJoin(target->Target->GetInstallIncludeDirectoriesEntries(te), ";"),
preprocessRule, true);
this->ReplaceInstallPrefix(dirs);
std::unique_ptr<cmCompiledGeneratorExpression> cge = ge.Parse(dirs);
diff --git a/Source/cmExportFileGenerator.h b/Source/cmExportFileGenerator.h
index 5875247..d50f7e8 100644
--- a/Source/cmExportFileGenerator.h
+++ b/Source/cmExportFileGenerator.h
@@ -148,7 +148,8 @@ protected:
void PopulateIncludeDirectoriesInterface(
cmGeneratorTarget const* target,
cmGeneratorExpression::PreprocessContext preprocessRule,
- ImportPropertyMap& properties, std::vector<std::string>& missingTargets);
+ ImportPropertyMap& properties, std::vector<std::string>& missingTargets,
+ cmTargetExport const& te);
void PopulateSourcesInterface(
cmGeneratorTarget const* target,
cmGeneratorExpression::PreprocessContext preprocessRule,
diff --git a/Source/cmExportInstallFileGenerator.cxx b/Source/cmExportInstallFileGenerator.cxx
index 2dd8b8f..f232440 100644
--- a/Source/cmExportInstallFileGenerator.cxx
+++ b/Source/cmExportInstallFileGenerator.cxx
@@ -90,7 +90,8 @@ bool cmExportInstallFileGenerator::GenerateMainFile(std::ostream& os)
ImportPropertyMap properties;
this->PopulateIncludeDirectoriesInterface(
- gt, cmGeneratorExpression::InstallInterface, properties, missingTargets);
+ gt, cmGeneratorExpression::InstallInterface, properties, missingTargets,
+ *te);
this->PopulateSourcesInterface(gt, cmGeneratorExpression::InstallInterface,
properties, missingTargets);
this->PopulateInterfaceProperty("INTERFACE_SYSTEM_INCLUDE_DIRECTORIES", gt,
diff --git a/Source/cmInstallCommand.cxx b/Source/cmInstallCommand.cxx
index 52a411b..a77b26b 100644
--- a/Source/cmInstallCommand.cxx
+++ b/Source/cmInstallCommand.cxx
@@ -760,7 +760,7 @@ bool HandleTargetsMode(std::vector<std::string> const& args,
te->FileSetGenerators[gen->GetFileSet()] = gen.get();
}
target.AddInstallIncludeDirectories(
- cmMakeRange(includesArgs.GetIncludeDirs()));
+ *te, cmMakeRange(includesArgs.GetIncludeDirs()));
te->NamelinkOnly = namelinkOnly;
helper.Makefile->GetGlobalGenerator()
->GetExportSets()[exports]
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 87fce92..6059055 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -192,7 +192,8 @@ public:
cmTarget::LinkLibraryVectorType OriginalLinkLibraries;
std::map<std::string, BTs<std::string>> LanguageStandardProperties;
std::vector<BT<std::string>> IncludeDirectoriesEntries;
- std::vector<std::string> InstallIncludeDirectoriesEntries;
+ std::map<cmTargetExport const*, std::vector<std::string>>
+ InstallIncludeDirectoriesEntries;
std::vector<BT<std::string>> CompileOptionsEntries;
std::vector<BT<std::string>> CompileFeaturesEntries;
std::vector<BT<std::string>> CompileDefinitionsEntries;
@@ -1079,15 +1080,18 @@ std::set<std::string> const& cmTarget::GetSystemIncludeDirectories() const
return this->impl->SystemIncludeDirectories;
}
-void cmTarget::AddInstallIncludeDirectories(cmStringRange const& incs)
+void cmTarget::AddInstallIncludeDirectories(cmTargetExport const& te,
+ cmStringRange const& incs)
{
- std::copy(incs.begin(), incs.end(),
- std::back_inserter(this->impl->InstallIncludeDirectoriesEntries));
+ std::copy(
+ incs.begin(), incs.end(),
+ std::back_inserter(this->impl->InstallIncludeDirectoriesEntries[&te]));
}
-cmStringRange cmTarget::GetInstallIncludeDirectoriesEntries() const
+cmStringRange cmTarget::GetInstallIncludeDirectoriesEntries(
+ cmTargetExport const& te) const
{
- return cmMakeRange(this->impl->InstallIncludeDirectoriesEntries);
+ return cmMakeRange(this->impl->InstallIncludeDirectoriesEntries[&te]);
}
cmBTStringRange cmTarget::GetIncludeDirectoriesEntries() const
diff --git a/Source/cmTarget.h b/Source/cmTarget.h
index 18e39c7..0cdd2fc 100644
--- a/Source/cmTarget.h
+++ b/Source/cmTarget.h
@@ -27,6 +27,7 @@ class cmListFileContext;
class cmMakefile;
class cmPropertyMap;
class cmSourceFile;
+class cmTargetExport;
class cmTargetInternals;
template <typename T>
@@ -237,8 +238,10 @@ public:
void AddSystemIncludeDirectories(std::set<std::string> const& incs);
std::set<std::string> const& GetSystemIncludeDirectories() const;
- void AddInstallIncludeDirectories(cmStringRange const& incs);
- cmStringRange GetInstallIncludeDirectoriesEntries() const;
+ void AddInstallIncludeDirectories(cmTargetExport const& te,
+ cmStringRange const& incs);
+ cmStringRange GetInstallIncludeDirectoriesEntries(
+ cmTargetExport const& te) const;
BTs<std::string> const* GetLanguageStandardProperty(
const std::string& propertyName) const;