summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.h
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2015-08-27 14:07:32 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2015-08-27 14:07:32 (GMT)
commit27e4b21dfa926a522bb32674b8836ebb79d51bc5 (patch)
tree833b5c282f4a5c8ab6ee76bfcfad1317ee3ee085 /Source/cmTarget.h
parent445077cbd2343050250eb0d541633010db659312 (diff)
parentc2b7336ff3122c57a235aeaa1699ba5627ecf3ce (diff)
downloadCMake-27e4b21dfa926a522bb32674b8836ebb79d51bc5.zip
CMake-27e4b21dfa926a522bb32674b8836ebb79d51bc5.tar.gz
CMake-27e4b21dfa926a522bb32674b8836ebb79d51bc5.tar.bz2
Merge topic 'use-generator-target'
c2b7336f cmGeneratorTarget: Move GetConfigCommonSourceFiles from cmTarget. 69329fff cmGeneratorTarget: Move GetLanguages from cmTarget. 0431f2c4 cmGeneratorTarget: Move ComputeLinkImplementationLanguages from cmTarget. abe9505d cmGeneratorTarget: Move HaveBuildTreeRPath from cmTarget. d4a24c0e cmGeneratorTarget: Move GetLinkImplementation from cmTarget. 83981cf5 cmTarget: Add GetLinkImplMap method. 771e79a2 cmLinkItem: Add cmOptionalLinkImplementation type. 3846ebcf cmLinkItem: Add cmLinkImplementation type. a7f5d70d cmGeneratorTarget: Move compile defintions processing from cmTarget. d051086c cmGeneratorTarget: Move compile features processing from cmTarget. db4cb92b cmGeneratorTarget: Move compile options processing from cmTarget. e6ccbf6f cmGeneratorTarget: Move include directory processing from cmTarget. 8bfb0c53 cmGeneratorTarget: Move link iface helpers from cmTarget. 2cb3e574 cmGeneratorTarget: Move GetImportLinkInterface from cmTarget. 6d3d099b cmGeneratorTarget: Move ComputeLinkInterfaceLibraries from cmTarget. 0db9d927 cmGeneratorTarget: Move GetLinkInterfaceLibraries from cmTarget. ...
Diffstat (limited to 'Source/cmTarget.h')
-rw-r--r--Source/cmTarget.h107
1 files changed, 19 insertions, 88 deletions
diff --git a/Source/cmTarget.h b/Source/cmTarget.h
index dccf550..c86ec24 100644
--- a/Source/cmTarget.h
+++ b/Source/cmTarget.h
@@ -132,15 +132,11 @@ public:
void AddPostBuildCommand(cmCustomCommand const &cmd)
{this->PostBuildCommands.push_back(cmd);}
- void Compute();
-
/**
* Get the list of the source files used by this target
*/
void GetSourceFiles(std::vector<cmSourceFile*> &files,
const std::string& config) const;
- bool GetConfigCommonSourceFiles(std::vector<cmSourceFile*>& files) const;
-
/**
* Add sources to the target.
*/
@@ -233,54 +229,16 @@ public:
void GetObjectLibrariesCMP0026(std::vector<cmTarget*>& objlibs) const;
- /** The link interface specifies transitive library dependencies and
- other information needed by targets that link to this target. */
- struct LinkInterfaceLibraries
- {
- // Libraries listed in the interface.
- std::vector<cmLinkItem> Libraries;
- };
- struct LinkInterface: public LinkInterfaceLibraries
- {
- // Languages whose runtime libraries must be linked.
- std::vector<std::string> Languages;
-
- // Shared library dependencies needed for linking on some platforms.
- std::vector<cmLinkItem> SharedDeps;
-
- // Number of repetitions of a strongly connected component of two
- // or more static libraries.
- int Multiplicity;
-
- // Libraries listed for other configurations.
- // Needed only for OLD behavior of CMP0003.
- std::vector<cmLinkItem> WrongConfigLibraries;
-
- bool ImplementationIsInterface;
-
- LinkInterface(): Multiplicity(0), ImplementationIsInterface(false) {}
- };
-
- /** Get the link interface for the given configuration. Returns 0
- if the target cannot be linked. */
- LinkInterface const* GetLinkInterface(const std::string& config,
- cmTarget const* headTarget) const;
- LinkInterfaceLibraries const*
- GetLinkInterfaceLibraries(const std::string& config,
- cmTarget const* headTarget,
- bool usage_requirements_only) const;
-
- struct LinkImplementation: public cmLinkImplementationLibraries
- {
- // Languages whose runtime libraries must be linked.
- std::vector<std::string> Languages;
- };
- LinkImplementation const*
- GetLinkImplementation(const std::string& config) const;
-
cmLinkImplementationLibraries const*
GetLinkImplementationLibraries(const std::string& config) const;
+ void ComputeLinkImplementationLibraries(const std::string& config,
+ cmOptionalLinkImplementation& impl,
+ cmTarget const* head) const;
+
+ cmOptionalLinkImplementation&
+ GetLinkImplMap(std::string const& config) const;
+
cmTarget const* FindTargetToLink(std::string const& name) const;
/** Strip off leading and trailing whitespace from an item named in
@@ -331,7 +289,6 @@ public:
bool GetImplibGNUtoMS(std::string const& gnuName, std::string& out,
const char* newExt = 0) const;
- bool HaveBuildTreeRPATH(const std::string& config) const;
bool HaveInstallTreeRPATH() const;
// Get the properties
@@ -346,18 +303,6 @@ public:
If no macro should be defined null is returned. */
const char* GetExportMacro() const;
- void GetCompileDefinitions(std::vector<std::string> &result,
- const std::string& config,
- const std::string& language) const;
-
- // Compute the set of languages compiled by the target. This is
- // computed every time it is called because the languages can change
- // when source file properties are changed and we do not have enough
- // information to forward these property changes to the targets
- // until we have per-target object file properties.
- void GetLanguages(std::set<std::string>& languages,
- std::string const& config) const;
-
/** Return whether this target is an executable with symbol exports
enabled. */
bool IsExecutableWithExports() const;
@@ -401,9 +346,6 @@ public:
/** @return whether this target have a well defined output file name. */
bool HaveWellDefinedOutputFiles() const;
- std::vector<std::string> GetIncludeDirectories(
- const std::string& config,
- const std::string& language) const;
void InsertInclude(std::string const& entry,
cmListFileBacktrace const& bt,
bool before = false);
@@ -415,12 +357,6 @@ public:
void AppendBuildInterfaceIncludes();
- void GetCompileOptions(std::vector<std::string> &result,
- const std::string& config,
- const std::string& language) const;
- void GetCompileFeatures(std::vector<std::string> &features,
- const std::string& config) const;
-
bool IsNullImpliedByLinkLibraries(const std::string &p) const;
std::string GetDebugGeneratorExpressions(const std::string &value,
@@ -439,6 +375,18 @@ public:
return this->MaxLanguageStandards;
}
+ cmStringRange GetIncludeDirectoriesEntries() const;
+ cmBacktraceRange GetIncludeDirectoriesBacktraces() const;
+
+ cmStringRange GetCompileOptionsEntries() const;
+ cmBacktraceRange GetCompileOptionsBacktraces() const;
+
+ cmStringRange GetCompileFeaturesEntries() const;
+ cmBacktraceRange GetCompileFeaturesBacktraces() const;
+
+ cmStringRange GetCompileDefinitionsEntries() const;
+ cmBacktraceRange GetCompileDefinitionsBacktraces() const;
+
#if defined(_WIN32) && !defined(__CYGWIN__)
const LinkLibraryVectorType &GetLinkLibrariesForVS6() const {
return this->LinkLibrariesForVS6;}
@@ -553,11 +501,7 @@ private:
bool IsApple;
bool IsImportedTarget;
bool BuildInterfaceIncludesAppended;
- mutable bool DebugIncludesDone;
- mutable bool DebugCompileOptionsDone;
- mutable bool DebugCompileDefinitionsDone;
mutable bool DebugSourcesDone;
- mutable bool DebugCompileFeaturesDone;
mutable bool LinkImplementationLanguageIsContextDependent;
#if defined(_WIN32) && !defined(__CYGWIN__)
bool LinkLibrariesForVS6Analyzed;
@@ -591,23 +535,10 @@ private:
void ComputeImportInfo(std::string const& desired_config,
ImportInfo& info) const;
-
- LinkInterface const*
- GetImportLinkInterface(const std::string& config, cmTarget const* head,
- bool usage_requirements_only) const;
-
cmLinkImplementationLibraries const*
GetLinkImplementationLibrariesInternal(const std::string& config,
cmTarget const* head) const;
- void ExpandLinkItems(std::string const& prop, std::string const& value,
- std::string const& config, cmTarget const* headTarget,
- bool usage_requirements_only,
- std::vector<cmLinkItem>& items,
- bool& hadHeadSensitiveCondition) const;
- void LookupLinkItems(std::vector<std::string> const& names,
- std::vector<cmLinkItem>& items) const;
-
std::string ProcessSourceItemCMP0049(const std::string& s);
void ClearLinkMaps();