[cmake-commits] alex committed CMakeLists.txt 1.367 1.368 cmExtraCodeBlocksGenerator.cxx 1.1 1.2 cmake.cxx 1.311 1.312

cmake-commits at cmake.org cmake-commits at cmake.org
Wed Jul 18 10:19:35 EDT 2007


Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv2125

Modified Files:
	CMakeLists.txt cmExtraCodeBlocksGenerator.cxx cmake.cxx 
Log Message:

ENH: build codeblocks generator also on Windows

Alex


Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/CMakeLists.txt,v
retrieving revision 1.367
retrieving revision 1.368
diff -u -d -r1.367 -r1.368
--- CMakeLists.txt	13 Jul 2007 04:58:43 -0000	1.367
+++ CMakeLists.txt	18 Jul 2007 14:19:33 -0000	1.368
@@ -173,10 +173,13 @@
 
 # Kdevelop only works on UNIX and not windows
 IF(UNIX)
-  SET(SRCS ${SRCS}
-    cmGlobalKdevelopGenerator.cxx
-    cmExtraCodeBlocksGenerator.cxx)
+  SET(SRCS ${SRCS} cmGlobalKdevelopGenerator.cxx)
 ENDIF(UNIX)
+
+IF(NOT CYGWIN)
+  SET(SRCS ${SRCS} cmExtraCodeBlocksGenerator.cxx)
+ENDIF(NOT CYGWIN)
+
 # XCode only works on apple
 IF(APPLE)
   SET(SRCS ${SRCS}

Index: cmake.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmake.cxx,v
retrieving revision 1.311
retrieving revision 1.312
diff -u -d -r1.311 -r1.312
--- cmake.cxx	17 Jul 2007 16:01:39 -0000	1.311
+++ cmake.cxx	18 Jul 2007 14:19:33 -0000	1.312
@@ -70,9 +70,12 @@
 #endif
 #include "cmGlobalUnixMakefileGenerator3.h"
 
+#if !defined(__CYGWIN__) && !defined(CMAKE_BOOT_MINGW)
+# include "cmExtraCodeBlocksGenerator.h"
+#endif
+
 #ifdef CMAKE_USE_KDEVELOP
 # include "cmGlobalKdevelopGenerator.h"
-# include "cmExtraCodeBlocksGenerator.h"
 #endif
 
 #include <stdlib.h> // required for atoi
@@ -1472,15 +1475,17 @@
 
 void cmake::AddDefaultExtraGenerators()
 {
+#if defined(CMAKE_BUILD_WITH_CMAKE)
 #if defined(_WIN32) && !defined(__CYGWIN__)
-# if !defined(CMAKE_BOOT_MINGW)
-  // e.g. codeblocks, kdevelop4 ?
-# endif
+  // e.g. kdevelop4 ?
 #endif
-// e.g. eclipse ?
-#ifdef CMAKE_USE_KDEVELOP
-  this->AddExtraGenerator(cmExtraCodeBlocksGenerator::GetActualName(), 
+
+#if !defined(__CYGWIN__)
+  this->AddExtraGenerator(cmExtraCodeBlocksGenerator::GetActualName(),
                           &cmExtraCodeBlocksGenerator::New);
+#endif
+
+#ifdef CMAKE_USE_KDEVELOP
   this->AddExtraGenerator(cmGlobalKdevelopGenerator::GetActualName(), 
                           &cmGlobalKdevelopGenerator::New);
   // for kdevelop also add the generator with just the name of the 
@@ -1488,6 +1493,8 @@
   this->ExtraGenerators[cmGlobalKdevelopGenerator::GetActualName()] 
                                              = &cmGlobalKdevelopGenerator::New;
 #endif
+
+#endif
 }
 
 

Index: cmExtraCodeBlocksGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmExtraCodeBlocksGenerator.cxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- cmExtraCodeBlocksGenerator.cxx	13 Jul 2007 04:58:43 -0000	1.1
+++ cmExtraCodeBlocksGenerator.cxx	18 Jul 2007 14:19:33 -0000	1.2
@@ -37,15 +37,19 @@
     "Project files for CodeBlocks will be created in the top directory "
     "and in every subdirectory which features a CMakeLists.txt file "
     "containing a PROJECT() call. "
-    "Additionally a hierarchy of UNIX makefiles is generated into the "
-    "build tree.  Any "
-    "standard UNIX-style make program can build the project through the "
-    "default make target.  A \"make install\" target is also provided.";
+    "Additionally a hierarchy of makefiles is generated into the "
+    "build tree.  The appropriate make program can build the project through "
+    "the default make target.  A \"make install\" target is also provided.";
 }
 
 cmExtraCodeBlocksGenerator::cmExtraCodeBlocksGenerator()
 :cmExternalMakefileProjectGenerator()
 {
+#if defined(_WIN32)
+  this->SupportedGlobalGenerators.push_back("NMake Makefiles");
+  this->SupportedGlobalGenerators.push_back("MSYS Makefiles");
+  this->SupportedGlobalGenerators.push_back("MinGW Makefiles");
+#endif
   this->SupportedGlobalGenerators.push_back("Unix Makefiles");
 }
 



More information about the Cmake-commits mailing list