cmTarget: Run old-style link dependencies only for VS 6

Invoke it at runtime only with the VS 6 generator.  No other generators
need it.
This commit is contained in:
Brad King 2014-07-14 14:38:58 -04:00
parent b3b44d138e
commit d57be904ae
3 changed files with 10 additions and 2 deletions

@ -214,6 +214,9 @@ public:
*/ */
virtual void FindMakeProgram(cmMakefile*); virtual void FindMakeProgram(cmMakefile*);
/** Is this the Visual Studio 6 generator? */
virtual bool IsForVS6() const { return false; }
///! Find a target by name by searching the local generators. ///! Find a target by name by searching the local generators.
cmTarget* FindTarget(const std::string& name, cmTarget* FindTarget(const std::string& name,
bool excludeAliases = false) const; bool excludeAliases = false) const;

@ -91,6 +91,8 @@ public:
virtual void FindMakeProgram(cmMakefile*); virtual void FindMakeProgram(cmMakefile*);
virtual bool IsForVS6() const { return true; }
protected: protected:
virtual const char* GetIDEVersion() { return "6.0"; } virtual const char* GetIDEVersion() { return "6.0"; }
private: private:

@ -517,8 +517,11 @@ void cmTarget::FinishConfigure()
// invalidation code in this source file is buggy. // invalidation code in this source file is buggy.
this->ClearLinkMaps(); this->ClearLinkMaps();
// Do old-style link dependency analysis. // Do old-style link dependency analysis only for CM_USE_OLD_VS6.
this->AnalyzeLibDependenciesForVS6(*this->Makefile); if(this->Makefile->GetLocalGenerator()->GetGlobalGenerator()->IsForVS6())
{
this->AnalyzeLibDependenciesForVS6(*this->Makefile);
}
} }
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------