ENH: Enabling cmLocalUnixMakefileGenerator2 (new makefile generator) by default.
This commit is contained in:
parent
e979735a19
commit
2aa613b98c
@ -16,7 +16,7 @@
|
|||||||
=========================================================================*/
|
=========================================================================*/
|
||||||
|
|
||||||
#include "cmGlobalUnixMakefileGenerator.h"
|
#include "cmGlobalUnixMakefileGenerator.h"
|
||||||
#include "cmLocalUnixMakefileGenerator.h"
|
#include "cmLocalUnixMakefileGenerator2.h"
|
||||||
#include "cmMakefile.h"
|
#include "cmMakefile.h"
|
||||||
#include "cmake.h"
|
#include "cmake.h"
|
||||||
|
|
||||||
@ -31,6 +31,7 @@ void cmGlobalUnixMakefileGenerator::EnableLanguage(std::vector<std::string>const
|
|||||||
cmMakefile *mf)
|
cmMakefile *mf)
|
||||||
{
|
{
|
||||||
mf->AddDefinition("CMAKE_CFG_INTDIR",".");
|
mf->AddDefinition("CMAKE_CFG_INTDIR",".");
|
||||||
|
mf->AddDefinition("CMAKE_GENERATOR_NEW", "1");
|
||||||
this->cmGlobalGenerator::EnableLanguage(languages, mf);
|
this->cmGlobalGenerator::EnableLanguage(languages, mf);
|
||||||
std::string path;
|
std::string path;
|
||||||
for(std::vector<std::string>::const_iterator l = languages.begin();
|
for(std::vector<std::string>::const_iterator l = languages.begin();
|
||||||
@ -73,7 +74,7 @@ void cmGlobalUnixMakefileGenerator::EnableLanguage(std::vector<std::string>const
|
|||||||
///! Create a local generator appropriate to this Global Generator
|
///! Create a local generator appropriate to this Global Generator
|
||||||
cmLocalGenerator *cmGlobalUnixMakefileGenerator::CreateLocalGenerator()
|
cmLocalGenerator *cmGlobalUnixMakefileGenerator::CreateLocalGenerator()
|
||||||
{
|
{
|
||||||
cmLocalGenerator *lg = new cmLocalUnixMakefileGenerator;
|
cmLocalGenerator* lg = new cmLocalUnixMakefileGenerator2;
|
||||||
lg->SetGlobalGenerator(this);
|
lg->SetGlobalGenerator(this);
|
||||||
return lg;
|
return lg;
|
||||||
}
|
}
|
||||||
|
@ -25,9 +25,10 @@
|
|||||||
#if defined(CMAKE_BUILD_WITH_CMAKE)
|
#if defined(CMAKE_BUILD_WITH_CMAKE)
|
||||||
# include "cmVariableWatch.h"
|
# include "cmVariableWatch.h"
|
||||||
# include "cmVersion.h"
|
# include "cmVersion.h"
|
||||||
# include "cmLocalUnixMakefileGenerator2.h"
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include "cmLocalUnixMakefileGenerator2.h"
|
||||||
|
|
||||||
// only build kdevelop generator on non-windows platforms
|
// only build kdevelop generator on non-windows platforms
|
||||||
// when not bootstrapping cmake
|
// when not bootstrapping cmake
|
||||||
#if !defined(_WIN32)
|
#if !defined(_WIN32)
|
||||||
@ -291,20 +292,11 @@ void cmake::SetArgs(const std::vector<std::string>& args)
|
|||||||
}
|
}
|
||||||
else if(arg.find("-S",0) == 0)
|
else if(arg.find("-S",0) == 0)
|
||||||
{
|
{
|
||||||
directoriesSet = true;
|
// There is no local generate anymore. Ignore -S option.
|
||||||
m_Local = true;
|
|
||||||
std::string path = arg.substr(2);
|
|
||||||
path = cmSystemTools::CollapseFullPath(path.c_str());
|
|
||||||
cmSystemTools::ConvertToUnixSlashes(path);
|
|
||||||
this->SetStartDirectory(path.c_str());
|
|
||||||
}
|
}
|
||||||
else if(arg.find("-O",0) == 0)
|
else if(arg.find("-O",0) == 0)
|
||||||
{
|
{
|
||||||
directoriesSet = true;
|
// There is no local generate anymore. Ignore -O option.
|
||||||
std::string path = arg.substr(2);
|
|
||||||
path = cmSystemTools::CollapseFullPath(path.c_str());
|
|
||||||
cmSystemTools::ConvertToUnixSlashes(path);
|
|
||||||
this->SetStartOutputDirectory(path.c_str());
|
|
||||||
}
|
}
|
||||||
else if(arg.find("-B",0) == 0)
|
else if(arg.find("-B",0) == 0)
|
||||||
{
|
{
|
||||||
@ -839,13 +831,11 @@ int cmake::CMakeCommand(std::vector<std::string>& args)
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CMAKE_BUILD_WITH_CMAKE
|
|
||||||
// Internal CMake dependency scanning support.
|
// Internal CMake dependency scanning support.
|
||||||
else if (args[1] == "cmake_depends" && args.size() >= 5)
|
else if (args[1] == "cmake_depends" && args.size() >= 5)
|
||||||
{
|
{
|
||||||
return cmLocalUnixMakefileGenerator2::ScanDependencies(args)? 0 : 1;
|
return cmLocalUnixMakefileGenerator2::ScanDependencies(args)? 0 : 1;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(_WIN32) && !defined(__CYGWIN__)
|
#if defined(_WIN32) && !defined(__CYGWIN__)
|
||||||
// Write registry value
|
// Write registry value
|
||||||
@ -1664,10 +1654,8 @@ int cmake::CheckBuildSystem()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(CMAKE_BUILD_WITH_CMAKE)
|
|
||||||
// We do not need to rerun CMake. Check dependency integrity.
|
// We do not need to rerun CMake. Check dependency integrity.
|
||||||
cmLocalUnixMakefileGenerator2::CheckDependencies(mf);
|
cmLocalUnixMakefileGenerator2::CheckDependencies(mf);
|
||||||
#endif
|
|
||||||
|
|
||||||
// No need to rerun.
|
// No need to rerun.
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -36,6 +36,8 @@ CMAKE_CXX_SOURCES="\
|
|||||||
cmake \
|
cmake \
|
||||||
cmakewizard \
|
cmakewizard \
|
||||||
cmakemain \
|
cmakemain \
|
||||||
|
cmDepends \
|
||||||
|
cmDependsC \
|
||||||
cmMakeDepend \
|
cmMakeDepend \
|
||||||
cmMakefile \
|
cmMakefile \
|
||||||
cmGeneratedFileStream \
|
cmGeneratedFileStream \
|
||||||
@ -48,6 +50,7 @@ CMAKE_CXX_SOURCES="\
|
|||||||
cmLocalXCodeGenerator \
|
cmLocalXCodeGenerator \
|
||||||
cmXCodeObject \
|
cmXCodeObject \
|
||||||
cmLocalUnixMakefileGenerator \
|
cmLocalUnixMakefileGenerator \
|
||||||
|
cmLocalUnixMakefileGenerator2 \
|
||||||
cmBootstrapCommands \
|
cmBootstrapCommands \
|
||||||
cmCommands \
|
cmCommands \
|
||||||
cmTarget \
|
cmTarget \
|
||||||
|
Loading…
x
Reference in New Issue
Block a user