diff options
author | Bill Hoffman <bill.hoffman@kitware.com> | 2003-08-21 20:22:23 (GMT) |
---|---|---|
committer | Bill Hoffman <bill.hoffman@kitware.com> | 2003-08-21 20:22:23 (GMT) |
commit | a413160fecc73bf61fccff9b74d6e18349eeb861 (patch) | |
tree | 5cbc485d7850ebc5200d8f094ba1559b1bc202e8 /Source/cmake.cxx | |
parent | 0270b60b8f32c0da9bbe66ebee6aea92ab177c3c (diff) | |
download | CMake-a413160fecc73bf61fccff9b74d6e18349eeb861.zip CMake-a413160fecc73bf61fccff9b74d6e18349eeb861.tar.gz CMake-a413160fecc73bf61fccff9b74d6e18349eeb861.tar.bz2 |
ENH: add the unix makefile generator as an option from the windows GUI, this builds with mingw, cygwin, and combinations of make cl, bcc32
Diffstat (limited to 'Source/cmake.cxx')
-rw-r--r-- | Source/cmake.cxx | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx index e2dee84..c4c73dd 100644 --- a/Source/cmake.cxx +++ b/Source/cmake.cxx @@ -26,10 +26,13 @@ // include the generator #if defined(_WIN32) && !defined(__CYGWIN__) #include "cmGlobalVisualStudio6Generator.h" +#if !defined(__MINGW32__) #include "cmGlobalVisualStudio7Generator.h" #include "cmGlobalVisualStudio71Generator.h" +#endif #include "cmGlobalBorlandMakefileGenerator.h" #include "cmGlobalNMakeMakefileGenerator.h" +#include "cmGlobalUnixMakefileGenerator.h" #include "cmWin32ProcessExecution.h" #else #include "cmGlobalUnixMakefileGenerator.h" @@ -795,6 +798,10 @@ void cmake::SetGlobalGenerator(cmGlobalGenerator *gg) // set the new m_GlobalGenerator = gg; + // set the global flag for unix style paths on cmSystemTools as + // soon as the generator is set. This allows gmake to be used + // on windows. + cmSystemTools::SetForceUnixPaths(m_GlobalGenerator->GetForceUnixPaths()); // Save the environment variables CXX and CC m_CXXEnvironment = getenv("CXX"); m_CCEnvironment = getenv("CC"); @@ -877,6 +884,10 @@ int cmake::Configure() if(genName) { m_GlobalGenerator = this->CreateGlobalGenerator(genName); + // set the global flag for unix style paths on cmSystemTools as + // soon as the generator is set. This allows gmake to be used + // on windows. + cmSystemTools::SetForceUnixPaths(m_GlobalGenerator->GetForceUnixPaths()); } else { @@ -1065,6 +1076,10 @@ int cmake::LocalGenerate() if(genName) { m_GlobalGenerator = this->CreateGlobalGenerator(genName); + // set the global flag for unix style paths on cmSystemTools as + // soon as the generator is set. This allows gmake to be used + // on windows. + cmSystemTools::SetForceUnixPaths(m_GlobalGenerator->GetForceUnixPaths()); } else { @@ -1151,10 +1166,12 @@ void cmake::AddDefaultGenerators() #if defined(_WIN32) && !defined(__CYGWIN__) m_Generators[cmGlobalVisualStudio6Generator::GetActualName()] = &cmGlobalVisualStudio6Generator::New; +#if !defined(__MINGW32__) m_Generators[cmGlobalVisualStudio7Generator::GetActualName()] = &cmGlobalVisualStudio7Generator::New; m_Generators[cmGlobalVisualStudio71Generator::GetActualName()] = &cmGlobalVisualStudio71Generator::New; +#endif m_Generators[cmGlobalBorlandMakefileGenerator::GetActualName()] = &cmGlobalBorlandMakefileGenerator::New; m_Generators[cmGlobalNMakeMakefileGenerator::GetActualName()] = @@ -1164,9 +1181,9 @@ void cmake::AddDefaultGenerators() m_Generators[cmGlobalCodeWarriorGenerator::GetActualName()] = &cmGlobalCodeWarriorGenerator::New; # endif +#endif m_Generators[cmGlobalUnixMakefileGenerator::GetActualName()] = &cmGlobalUnixMakefileGenerator::New; -#endif } int cmake::LoadCache() |