[Cmake-commits] CMake branch, next, updated. v2.8.10.1-975-g6088588

David Cole david.cole at kitware.com
Wed Nov 21 14:21:26 EST 2012


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  6088588d4ad1b724e818ba2bc4af0be0c7cf31c8 (commit)
       via  7ae7d6650344f7a36216af8424abbf0b834688d1 (commit)
      from  1b481a0a3438c8a46a32e8c5be8504f1c32a193d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=6088588d4ad1b724e818ba2bc4af0be0c7cf31c8
commit 6088588d4ad1b724e818ba2bc4af0be0c7cf31c8
Merge: 1b481a0 7ae7d66
Author:     David Cole <david.cole at kitware.com>
AuthorDate: Wed Nov 21 14:21:24 2012 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Wed Nov 21 14:21:24 2012 -0500

    Merge topic 'fix-13392-nmake-empty-depends-problem' into next
    
    7ae7d66 NMake: Fix problem with empty DEPENDS args (#13392)


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=7ae7d6650344f7a36216af8424abbf0b834688d1
commit 7ae7d6650344f7a36216af8424abbf0b834688d1
Author:     David Cole <david.cole at kitware.com>
AuthorDate: Wed Nov 21 11:23:14 2012 -0500
Commit:     David Cole <david.cole at kitware.com>
CommitDate: Wed Nov 21 11:29:38 2012 -0500

    NMake: Fix problem with empty DEPENDS args (#13392)
    
    add_custom_command can have empty DEPENDS arguments, which
    was triggering invalid makefile generation for the NMake
    Makefiles generator. We were mistakenly emitting the build
    directory appended with "/" plus the empty string... which
    was then translated to a string ending in \" in build.make...
    which nmake choked on.
    
    The solution is not to emit any dependency when the input
    DEPENDS is the empty string. Return early from GetRealDependency
    in this empty input case.

diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 4952a8c..d48f43a 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -1875,6 +1875,14 @@ bool cmLocalGenerator::GetRealDependency(const char* inName,
   // modify the name so stripping down to just the file name should
   // produce the target name in this case.
   std::string name = cmSystemTools::GetFilenameName(inName);
+
+  // If the input name is the empty string, there is no real
+  // dependency. Short-circuit the other checks:
+  if(name == "")
+    {
+    return false;
+    }
+
   if(cmSystemTools::GetFilenameLastExtension(name) == ".exe")
     {
     name = cmSystemTools::GetFilenameWithoutLastExtension(name);

-----------------------------------------------------------------------

Summary of changes:
 Source/cmLocalGenerator.cxx |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list