From fbdac25f8182a6a33e6c3baa90cce55b9417a6af Mon Sep 17 00:00:00 2001 From: Andy Cedilnik Date: Sun, 9 Jul 2006 13:19:36 -0400 Subject: [PATCH] ENH: Add a copy constructor to copy the values --- Source/cmMakefile.cxx | 41 +++++++++++++++++++++++++++++++++++++++++ Source/cmMakefile.h | 1 + 2 files changed, 42 insertions(+) diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx index ff35cf877..49bf64722 100644 --- a/Source/cmMakefile.cxx +++ b/Source/cmMakefile.cxx @@ -90,6 +90,47 @@ cmMakefile::cmMakefile() this->PreOrder = false; } +cmMakefile::cmMakefile(const cmMakefile& mf) +{ + this->Prefix = mf.Prefix; + this->AuxSourceDirectories = mf.AuxSourceDirectories; + this->cmStartDirectory = mf.cmStartDirectory; + this->StartOutputDirectory = mf.StartOutputDirectory; + this->cmHomeDirectory = mf.cmHomeDirectory; + this->HomeOutputDirectory = mf.HomeOutputDirectory; + this->cmCurrentListFile = mf.cmCurrentListFile; + this->ProjectName = mf.ProjectName; + this->Targets = mf.Targets; + this->SourceFiles = mf.SourceFiles; + this->Tests = mf.Tests; + this->IncludeDirectories = mf.IncludeDirectories; + this->LinkDirectories = mf.LinkDirectories; + this->ListFiles = mf.ListFiles; + this->OutputFiles = mf.OutputFiles; + this->LinkLibraries = mf.LinkLibraries; + this->InstallGenerators = mf.InstallGenerators; + this->IncludeFileRegularExpression = mf.IncludeFileRegularExpression; + this->ComplainFileRegularExpression = mf.ComplainFileRegularExpression; + this->SourceFileExtensions = mf.SourceFileExtensions; + this->HeaderFileExtensions = mf.HeaderFileExtensions; + this->DefineFlags = mf.DefineFlags; + +#if defined(CMAKE_BUILD_WITH_CMAKE) + this->SourceGroups = mf.SourceGroups; +#endif + + this->Definitions = mf.Definitions; + this->LocalGenerator = mf.LocalGenerator; + this->FunctionBlockers = mf.FunctionBlockers; + this->DataMap = mf.DataMap; + this->MacrosMap = mf.MacrosMap; + this->SubDirectoryOrder = mf.SubDirectoryOrder; + this->TemporaryDefinitionKey = mf.TemporaryDefinitionKey; + this->Properties = mf.Properties; + this->PreOrder = mf.PreOrder; + this->ListFileStack = mf.ListFileStack; +} + const char* cmMakefile::GetReleaseVersion() { #if CMake_VERSION_MINOR & 1 diff --git a/Source/cmMakefile.h b/Source/cmMakefile.h index b502c4de7..2cb8f8ffa 100644 --- a/Source/cmMakefile.h +++ b/Source/cmMakefile.h @@ -69,6 +69,7 @@ public: * Construct an empty makefile. */ cmMakefile(); + cmMakefile(const cmMakefile& mf); /** * Destructor.