diff options
author | Brad King <brad.king@kitware.com> | 2015-10-16 13:35:34 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2015-10-16 13:35:34 (GMT) |
commit | f13521317a43af4ebb2996c9916d1d1da695c5fc (patch) | |
tree | 25b68105cef1bbb59f0c9980fb86d72807a97c0a /Source/cmMakefileLibraryTargetGenerator.cxx | |
parent | a4f0b01939ca7c69c1e31f017c6e87b642388252 (diff) | |
parent | 55474e6182b49acc4183fffdebccc7ae2a7335fa (diff) | |
download | CMake-f13521317a43af4ebb2996c9916d1d1da695c5fc.zip CMake-f13521317a43af4ebb2996c9916d1d1da695c5fc.tar.gz CMake-f13521317a43af4ebb2996c9916d1d1da695c5fc.tar.bz2 |
Merge topic 'clean-up-cmTarget'
55474e61 cmState: Move GetTargetTypeName from cmTarget.
38df5c36 Remove now-obsolete casts.
4ee2b267 cmGeneratorTarget: Use enum for GetType.
eac15298 cmState: Move TargetType enum from cmTarget.
482b3811 cmTarget: Move link type enum out.
2ee1cb85 cmTarget: Move ImportInfoMap out of internal class.
a48bcabd cmTarget: Move backtrace member out of internal class.
6694d993 cmTarget: Remove unneeded constructors.
983c00f8 Generators: Use GetType from the cmGeneratorTarget.
Diffstat (limited to 'Source/cmMakefileLibraryTargetGenerator.cxx')
-rw-r--r-- | Source/cmMakefileLibraryTargetGenerator.cxx | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/Source/cmMakefileLibraryTargetGenerator.cxx b/Source/cmMakefileLibraryTargetGenerator.cxx index 1278dcd..a0aa10b 100644 --- a/Source/cmMakefileLibraryTargetGenerator.cxx +++ b/Source/cmMakefileLibraryTargetGenerator.cxx @@ -26,7 +26,7 @@ cmMakefileLibraryTargetGenerator cmMakefileTargetGenerator(target) { this->CustomCommandDriver = OnDepends; - if (this->Target->GetType() != cmTarget::INTERFACE_LIBRARY) + if (this->GeneratorTarget->GetType() != cmState::INTERFACE_LIBRARY) { this->GeneratorTarget->GetLibraryNames( this->TargetNameOut, this->TargetNameSO, this->TargetNameReal, @@ -62,12 +62,12 @@ void cmMakefileLibraryTargetGenerator::WriteRuleFiles() // write the link rules // Write the rule for this target type. - switch(this->Target->GetType()) + switch(this->GeneratorTarget->GetType()) { - case cmTarget::STATIC_LIBRARY: + case cmState::STATIC_LIBRARY: this->WriteStaticLibraryRules(); break; - case cmTarget::SHARED_LIBRARY: + case cmState::SHARED_LIBRARY: this->WriteSharedLibraryRules(false); if(this->GeneratorTarget->NeedRelinkBeforeInstall(this->ConfigName)) { @@ -75,7 +75,7 @@ void cmMakefileLibraryTargetGenerator::WriteRuleFiles() this->WriteSharedLibraryRules(true); } break; - case cmTarget::MODULE_LIBRARY: + case cmState::MODULE_LIBRARY: this->WriteModuleLibraryRules(false); if(this->GeneratorTarget->NeedRelinkBeforeInstall(this->ConfigName)) { @@ -83,7 +83,7 @@ void cmMakefileLibraryTargetGenerator::WriteRuleFiles() this->WriteModuleLibraryRules(true); } break; - case cmTarget::OBJECT_LIBRARY: + case cmState::OBJECT_LIBRARY: this->WriteObjectLibraryRules(); break; default: @@ -253,8 +253,8 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules this->LocalGenerator->AppendFlags(linkFlags, extraFlags); // Add OSX version flags, if any. - if(this->Target->GetType() == cmTarget::SHARED_LIBRARY || - this->Target->GetType() == cmTarget::MODULE_LIBRARY) + if(this->GeneratorTarget->GetType() == cmState::SHARED_LIBRARY || + this->GeneratorTarget->GetType() == cmState::MODULE_LIBRARY) { this->AppendOSXVerFlag(linkFlags, linkLanguage, "COMPATIBILITY", true); this->AppendOSXVerFlag(linkFlags, linkLanguage, "CURRENT", false); @@ -351,15 +351,15 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules // Add the link message. std::string buildEcho = "Linking "; buildEcho += linkLanguage; - switch(this->Target->GetType()) + switch(this->GeneratorTarget->GetType()) { - case cmTarget::STATIC_LIBRARY: + case cmState::STATIC_LIBRARY: buildEcho += " static library "; break; - case cmTarget::SHARED_LIBRARY: + case cmState::SHARED_LIBRARY: buildEcho += " shared library "; break; - case cmTarget::MODULE_LIBRARY: + case cmState::MODULE_LIBRARY: if (this->Target->IsCFBundleOnApple()) buildEcho += " CFBundle"; buildEcho += " shared module "; @@ -375,12 +375,12 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules } const char* forbiddenFlagVar = 0; - switch(this->Target->GetType()) + switch(this->GeneratorTarget->GetType()) { - case cmTarget::SHARED_LIBRARY: + case cmState::SHARED_LIBRARY: forbiddenFlagVar = "_CREATE_SHARED_LIBRARY_FORBIDDEN_FLAGS"; break; - case cmTarget::MODULE_LIBRARY: + case cmState::MODULE_LIBRARY: forbiddenFlagVar = "_CREATE_SHARED_MODULE_FORBIDDEN_FLAGS"; break; default: break; @@ -429,7 +429,7 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules #ifdef _WIN32 // There may be a manifest file for this target. Add it to the // clean set just in case. - if(this->Target->GetType() != cmTarget::STATIC_LIBRARY) + if(this->GeneratorTarget->GetType() != cmState::STATIC_LIBRARY) { libCleanFiles.push_back( this->Convert((targetFullPath+".manifest").c_str(), @@ -441,7 +441,7 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules std::vector<std::string> commands1; // Add a command to remove any existing files for this library. // for static libs only - if(this->Target->GetType() == cmTarget::STATIC_LIBRARY) + if(this->GeneratorTarget->GetType() == cmState::STATIC_LIBRARY) { this->LocalGenerator->AppendCleanCommand(commands1, libCleanFiles, this->GeneratorTarget, "target"); @@ -497,7 +497,7 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules std::vector<std::string> archiveAppendCommands; std::vector<std::string> archiveFinishCommands; std::string::size_type archiveCommandLimit = std::string::npos; - if(this->Target->GetType() == cmTarget::STATIC_LIBRARY) + if(this->GeneratorTarget->GetType() == cmState::STATIC_LIBRARY) { haveStaticLibraryRule = this->Makefile->GetDefinition(linkRuleVar)? true:false; @@ -552,7 +552,7 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules // Collect up flags to link in needed libraries. std::string linkLibs; - if(this->Target->GetType() != cmTarget::STATIC_LIBRARY) + if(this->GeneratorTarget->GetType() != cmState::STATIC_LIBRARY) { this->CreateLinkLibs(linkLibs, relink, useResponseFileForLibs, depends, useWatcomQuote); @@ -566,7 +566,7 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules useWatcomQuote); // maybe create .def file from list of objects - if (this->Target->GetType() == cmTarget::SHARED_LIBRARY && + if (this->GeneratorTarget->GetType() == cmState::SHARED_LIBRARY && this->Makefile->IsOn("CMAKE_SUPPORT_WINDOWS_EXPORT_ALL_SYMBOLS")) { if(this->Target->GetPropertyAsBool("WINDOWS_EXPORT_ALL_SYMBOLS")) @@ -667,7 +667,7 @@ void cmMakefileLibraryTargetGenerator::WriteLibraryRules // Compute the directory portion of the install_name setting. std::string install_name_dir; - if(this->Target->GetType() == cmTarget::SHARED_LIBRARY) + if(this->GeneratorTarget->GetType() == cmState::SHARED_LIBRARY) { // Get the install_name directory for the build tree. install_name_dir = |