[cmake-commits] king committed cmLocalVisualStudio7Generator.cxx 1.196 1.197

cmake-commits at cmake.org cmake-commits at cmake.org
Wed Aug 1 11:39:53 EDT 2007


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

Modified Files:
	cmLocalVisualStudio7Generator.cxx 
Log Message:
BUG: Do not recognize preprocessor definition flags for the linker which has no preprocessor but does have flags starting with /D.


Index: cmLocalVisualStudio7Generator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmLocalVisualStudio7Generator.cxx,v
retrieving revision 1.196
retrieving revision 1.197
diff -u -d -r1.196 -r1.197
--- cmLocalVisualStudio7Generator.cxx	31 Jul 2007 15:23:15 -0000	1.196
+++ cmLocalVisualStudio7Generator.cxx	1 Aug 2007 15:39:51 -0000	1.197
@@ -405,6 +405,7 @@
   // Unrecognized flags that get no special handling.
   cmStdString FlagString;
 
+  Tool CurrentTool;
   bool DoingDefine;
   cmVS7FlagTable const* FlagTable;
   cmVS7FlagTable const* ExtraFlagTable;
@@ -1630,6 +1631,7 @@
 cmLocalVisualStudio7GeneratorOptions
 ::cmLocalVisualStudio7GeneratorOptions(Tool tool,
                                        cmVS7FlagTable const* extraTable):
+  CurrentTool(tool),
   DoingDefine(false), FlagTable(0), ExtraFlagTable(extraTable)
 {
   // Choose the flag table for the requested tool.
@@ -1728,8 +1730,7 @@
   if(flag[0] == '-' || flag[0] == '/')
     {
     // Look for preprocessor definitions.
-    if(flag[1] == 'D' && strncmp(flag+1, "DEF:", 4) !=0 
-       && strcmp(flag+1, "DLL") != 0)
+    if(this->CurrentTool == Compiler && flag[1] == 'D')
       {
       if(flag[2] == '\0')
         {



More information about the Cmake-commits mailing list