[cmake-commits] king committed cmAddCustomTargetCommand.cxx 1.23 1.24 cmCPluginAPI.cxx 1.30 1.31 cmGlobalGenerator.cxx 1.152 1.153 cmGlobalVisualStudio6Generator.cxx 1.61 1.62 cmGlobalVisualStudio7Generator.cxx 1.74 1.75 cmGlobalVisualStudio8Generator.cxx 1.13 1.14 cmGlobalXCodeGenerator.cxx 1.122 1.123 cmIncludeExternalMSProjectCommand.cxx 1.15 1.16 cmMakefile.cxx 1.353 1.354 cmMakefile.h 1.191 1.192 cmVTKWrapJavaCommand.cxx 1.31 1.32

cmake-commits at cmake.org cmake-commits at cmake.org
Thu Sep 28 13:55:29 EDT 2006


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

Modified Files:
	cmAddCustomTargetCommand.cxx cmCPluginAPI.cxx 
	cmGlobalGenerator.cxx cmGlobalVisualStudio6Generator.cxx 
	cmGlobalVisualStudio7Generator.cxx 
	cmGlobalVisualStudio8Generator.cxx cmGlobalXCodeGenerator.cxx 
	cmIncludeExternalMSProjectCommand.cxx cmMakefile.cxx 
	cmMakefile.h cmVTKWrapJavaCommand.cxx 
Log Message:
ENH: Cleaned up signature of cmMakefile::AddUtilityCommand.  It is not valid to have an output from a utility rule and no calls to the method asked for an output anyway.  The argument has been removed.


Index: cmGlobalVisualStudio8Generator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmGlobalVisualStudio8Generator.cxx,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- cmGlobalVisualStudio8Generator.cxx	21 Sep 2006 19:14:06 -0000	1.13
+++ cmGlobalVisualStudio8Generator.cxx	28 Sep 2006 17:55:25 -0000	1.14
@@ -75,7 +75,6 @@
 {
   // Add a special target on which all other targets depend that
   // checks the build system and optionally re-runs CMake.
-  const char* no_output = 0;
   const char* no_working_directory = 0;
   std::vector<std::string> no_depends;
   std::map<cmStdString, std::vector<cmLocalGenerator*> >::iterator it;
@@ -90,10 +89,10 @@
         static_cast<cmLocalVisualStudio7Generator*>(generators[0]);
       cmMakefile* mf = lg->GetMakefile();
       std::string cmake_command = mf->GetRequiredDefinition("CMAKE_COMMAND");
+      cmCustomCommandLines noCommandLines;
       mf->AddUtilityCommand(CMAKE_CHECK_BUILD_SYSTEM_TARGET, true,
-                            no_output, no_depends,
-                            no_working_directory,
-                            "echo", "Checking build system");
+                            no_working_directory, no_depends,
+                            noCommandLines);
       cmTarget* tgt = mf->FindTarget(CMAKE_CHECK_BUILD_SYSTEM_TARGET);
       if(!tgt)
         {

Index: cmGlobalXCodeGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmGlobalXCodeGenerator.cxx,v
retrieving revision 1.122
retrieving revision 1.123
diff -u -d -r1.122 -r1.123
--- cmGlobalXCodeGenerator.cxx	27 Sep 2006 17:43:45 -0000	1.122
+++ cmGlobalXCodeGenerator.cxx	28 Sep 2006 17:55:25 -0000	1.123
@@ -281,10 +281,9 @@
 {
   cmMakefile* mf = root->GetMakefile();
   // Add ALL_BUILD
-  const char* no_output = 0;
   const char* no_working_directory = 0;
   std::vector<std::string> no_depends;
-  mf->AddUtilityCommand("ALL_BUILD", false, no_output, no_depends,
+  mf->AddUtilityCommand("ALL_BUILD", false, no_depends,
                         no_working_directory,
                         "echo", "Build all projects");
   cmTarget* allbuild = mf->FindTarget("ALL_BUILD");
@@ -307,7 +306,7 @@
     }
   cmCustomCommandLines commandLines;
   commandLines.push_back(makecommand);
-  mf->AddUtilityCommand("XCODE_DEPEND_HELPER", false, no_output,
+  mf->AddUtilityCommand("XCODE_DEPEND_HELPER", false,
                         no_working_directory,
                         no_depends,
                         commandLines);

Index: cmAddCustomTargetCommand.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmAddCustomTargetCommand.cxx,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -d -r1.23 -r1.24
--- cmAddCustomTargetCommand.cxx	28 Sep 2006 15:30:46 -0000	1.23
+++ cmAddCustomTargetCommand.cxx	28 Sep 2006 17:55:25 -0000	1.24
@@ -149,8 +149,7 @@
 
   // Add the utility target to the makefile.
   bool escapeOldStyle = !verbatim;
-  const char* no_output = 0;
-  this->Makefile->AddUtilityCommand(args[0].c_str(), all, no_output,
+  this->Makefile->AddUtilityCommand(args[0].c_str(), all,
                                     working_directory.c_str(), depends,
                                     commandLines, escapeOldStyle);
 

Index: cmGlobalGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmGlobalGenerator.cxx,v
retrieving revision 1.152
retrieving revision 1.153
diff -u -d -r1.152 -r1.153
--- cmGlobalGenerator.cxx	1 Sep 2006 13:51:28 -0000	1.152
+++ cmGlobalGenerator.cxx	28 Sep 2006 17:55:25 -0000	1.153
@@ -1300,7 +1300,6 @@
     // If the file doesn't exist, then ENABLE_TESTING hasn't been run
     if (total_tests > 0)
       {
-      const char* no_output = 0;
       const char* no_working_dir = 0;
       std::vector<std::string> no_depends;
       std::map<cmStdString, std::vector<cmLocalGenerator*> >::iterator it;
@@ -1313,7 +1312,7 @@
           cmMakefile* mf = gen[0]->GetMakefile();
           if(const char* outDir = mf->GetDefinition("CMAKE_CFG_INTDIR"))
             {
-            mf->AddUtilityCommand("RUN_TESTS", false, no_output, no_depends,
+            mf->AddUtilityCommand("RUN_TESTS", false, no_depends,
                                   no_working_dir, 
                                   ctest.c_str(), "-C", outDir);
             }

Index: cmVTKWrapJavaCommand.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmVTKWrapJavaCommand.cxx,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -d -r1.31 -r1.32
--- cmVTKWrapJavaCommand.cxx	12 May 2006 18:12:13 -0000	1.31
+++ cmVTKWrapJavaCommand.cxx	28 Sep 2006 17:55:26 -0000	1.32
@@ -190,9 +190,8 @@
     alldepends.push_back(res2);
     }
 
-  const char* no_output = 0;
   const char* no_working_directory = 0;
-  this->Makefile->AddUtilityCommand((this->LibraryName+"JavaClasses").c_str(),
-                                true, no_output, 
-                                alldepends, no_working_directory, "");
+  this->Makefile->AddUtilityCommand(
+    (this->LibraryName+"JavaClasses").c_str(),
+    true, alldepends, no_working_directory, "");
 }

Index: cmMakefile.h
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmMakefile.h,v
retrieving revision 1.191
retrieving revision 1.192
diff -u -d -r1.191 -r1.192
--- cmMakefile.h	28 Sep 2006 15:30:47 -0000	1.191
+++ cmMakefile.h	28 Sep 2006 17:55:26 -0000	1.192
@@ -183,7 +183,6 @@
    * is run every time the target is built.
    */
   void AddUtilityCommand(const char* utilityName, bool all,
-                         const char* output,
                          const std::vector<std::string>& depends,
                          const char* workingDirectory,
                          const char* command,
@@ -192,7 +191,6 @@
                          const char* arg3=0,
                          const char* arg4=0);
   void AddUtilityCommand(const char* utilityName, bool all,
-                         const char* output,
                          const char* workingDirectory,
                          const std::vector<std::string>& depends,
                          const cmCustomCommandLines& commandLines,

Index: cmIncludeExternalMSProjectCommand.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmIncludeExternalMSProjectCommand.cxx,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- cmIncludeExternalMSProjectCommand.cxx	11 May 2006 19:50:11 -0000	1.15
+++ cmIncludeExternalMSProjectCommand.cxx	28 Sep 2006 17:55:25 -0000	1.16
@@ -46,10 +46,9 @@
     utility_name += args[0];
     std::string path = args[1];
     cmSystemTools::ConvertToUnixSlashes(path);
-    const char* no_output = 0;
     const char* no_working_directory = 0;
     this->Makefile->AddUtilityCommand(utility_name.c_str(), true,
-                                  no_output, depends,
+                                  depends,
                                   no_working_directory,
                                   args[0].c_str(), path.c_str());
     

Index: cmCPluginAPI.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmCPluginAPI.cxx,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -d -r1.30 -r1.31
--- cmCPluginAPI.cxx	1 Aug 2006 18:31:24 -0000	1.30
+++ cmCPluginAPI.cxx	28 Sep 2006 17:55:25 -0000	1.31
@@ -206,8 +206,8 @@
                          int all,
                          int numDepends,
                          const char **depends,
-                         int numOutputs,
-                         const char **outputs)
+                         int,
+                         const char **)
 {
   // Get the makefile instance.  Perform an extra variable expansion
   // now because the API caller expects it.
@@ -234,19 +234,9 @@
     depends2.push_back(mf->ExpandVariablesInString(expand));
     }
 
-  // Only one output is allowed.
-  const char* output = 0;
-  std::string outputStr;
-  if(numOutputs > 0)
-    {
-    expand = outputs[0];
-    outputStr = mf->ExpandVariablesInString(expand);
-    output = outputStr.c_str();
-    }
-
   // Pass the call to the makefile instance.
   mf->AddUtilityCommand(utilityName, (all ? true : false),
-                        output, 0, depends2, commandLines);
+                        0, depends2, commandLines);
 }
 void CCONV cmAddCustomCommand(void *arg, const char* source,
                         const char* command,

Index: cmGlobalVisualStudio6Generator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmGlobalVisualStudio6Generator.cxx,v
retrieving revision 1.61
retrieving revision 1.62
diff -u -d -r1.61 -r1.62
--- cmGlobalVisualStudio6Generator.cxx	1 Jun 2006 19:51:24 -0000	1.61
+++ cmGlobalVisualStudio6Generator.cxx	28 Sep 2006 17:55:25 -0000	1.62
@@ -162,7 +162,6 @@
 {
   // add a special target that depends on ALL projects for easy build
   // of one configuration only.
-  const char* no_output = 0;
   std::vector<std::string> no_depends;
   const char* no_working_dir = 0;
   std::map<cmStdString, std::vector<cmLocalGenerator*> >::iterator it;
@@ -173,7 +172,7 @@
     if(gen.size())
       {
       gen[0]->GetMakefile()->AddUtilityCommand("ALL_BUILD", false, 
-                                               no_output, no_depends, 
+                                               no_depends, 
                                                no_working_dir,
                                                "echo", "Build all projects");
       }

Index: cmGlobalVisualStudio7Generator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmGlobalVisualStudio7Generator.cxx,v
retrieving revision 1.74
retrieving revision 1.75
diff -u -d -r1.74 -r1.75
--- cmGlobalVisualStudio7Generator.cxx	1 Jun 2006 19:51:24 -0000	1.74
+++ cmGlobalVisualStudio7Generator.cxx	28 Sep 2006 17:55:25 -0000	1.75
@@ -216,7 +216,6 @@
 {
   // add a special target that depends on ALL projects for easy build
   // of one configuration only.
-  const char* no_output = 0;
   const char* no_working_dir = 0;
   std::vector<std::string> no_depends;
   std::map<cmStdString, std::vector<cmLocalGenerator*> >::iterator it;
@@ -227,7 +226,7 @@
     if(gen.size())
       {
       gen[0]->GetMakefile()->
-        AddUtilityCommand("ALL_BUILD", false, no_output, no_depends,
+        AddUtilityCommand("ALL_BUILD", false, no_depends,
                           no_working_dir,
                           "echo", "Build all projects");
       std::string cmake_command = 

Index: cmMakefile.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmMakefile.cxx,v
retrieving revision 1.353
retrieving revision 1.354
diff -u -d -r1.353 -r1.354
--- cmMakefile.cxx	28 Sep 2006 15:30:46 -0000	1.353
+++ cmMakefile.cxx	28 Sep 2006 17:55:25 -0000	1.354
@@ -783,7 +783,6 @@
 
 //----------------------------------------------------------------------------
 void cmMakefile::AddUtilityCommand(const char* utilityName, bool all,
-                                   const char* output,
                                    const std::vector<std::string>& depends,
                                    const char* workingDirectory,
                                    const char* command,
@@ -815,13 +814,12 @@
   commandLines.push_back(commandLine);
 
   // Call the real signature of this method.
-  this->AddUtilityCommand(utilityName, all, output, workingDirectory, 
+  this->AddUtilityCommand(utilityName, all, workingDirectory, 
                           depends, commandLines);
 }
 
 //----------------------------------------------------------------------------
 void cmMakefile::AddUtilityCommand(const char* utilityName, bool all,
-                                   const char* output,
                                    const char* workingDirectory,
                                    const std::vector<std::string>& depends,
                                    const cmCustomCommandLines& commandLines,
@@ -834,10 +832,6 @@
   target.SetMakefile(this);
   // Store the custom command in the target.
   std::vector<std::string> outputs;
-  if(output)
-    {
-    outputs.push_back(output);
-    }
   cmCustomCommand cc(outputs, depends, commandLines, 0, workingDirectory);
   cc.SetEscapeOldStyle(escapeOldStyle);
   target.GetPostBuildCommands().push_back(cc);



More information about the Cmake-commits mailing list