Pre-compute object file names before VS project generation

Implement cmGlobalGenerator::ComputeTargetObjects in the VS generator
to pre-compute all the object file names.  Use the results during
generation instead of re-computing it later.
This commit is contained in:
Brad King
2012-03-07 14:04:33 -05:00
parent 3baaf6ccec
commit d57047de33
10 changed files with 104 additions and 136 deletions

View File

@@ -56,6 +56,8 @@ public:
/** Version of Visual Studio. */
VSVersion GetVersion() const { return this->Version; }
virtual std::string ComputeLongestObjectDirectory(cmTarget&) const = 0;
protected:
virtual const char* ReportErrorLabel() const;
virtual bool CustomCommandUseLocal() const { return false; }
@@ -64,12 +66,6 @@ protected:
cmsys::auto_ptr<cmCustomCommand>
MaybeCreateImplibDir(cmTarget& target, const char* config, bool isFortran);
// Safe object file name generation.
void ComputeObjectNameRequirements(std::vector<cmSourceFile*> const&);
bool SourceFileCompiles(const cmSourceFile* sf);
std::set<const cmSourceFile*> NeedObjectName;
friend class cmVisualStudio10TargetGenerator;
VSVersion Version;
};