CPack: Don't copy cmMakefile. Just push a scope instead.

This commit is contained in:
Stephen Kelly 2015-04-18 16:36:48 +02:00
parent f438cd3731
commit f3af9517ff

View File

@ -356,8 +356,8 @@ int main (int argc, char const* const* argv)
++it )
{
const char* gen = it->c_str();
cmMakefile newMF(*globalMF);
cmMakefile* mf = &newMF;
cmMakefile::ScopePushPop raii(globalMF);
cmMakefile* mf = globalMF;
cmCPack_Log(&log, cmCPackLog::LOG_VERBOSE,
"Specified generator: " << gen << std::endl);
if ( parsed && !mf->GetDefinition("CPACK_PACKAGE_NAME") )