[Cmake-commits] CMake branch, next, updated. v3.1.2-1171-ga06bd9f

Brad King brad.king at kitware.com
Tue Feb 10 10:35:26 EST 2015


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  a06bd9fdc9c2ac5a921f6836454fc13c7523d060 (commit)
       via  f3e9eeedf43f783c02b2a2a10fc0e632eaf7cfd0 (commit)
      from  5367c0e4781644a33ce9163666a626e50efffa2c (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=a06bd9fdc9c2ac5a921f6836454fc13c7523d060
commit a06bd9fdc9c2ac5a921f6836454fc13c7523d060
Merge: 5367c0e f3e9eee
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Tue Feb 10 10:35:25 2015 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Feb 10 10:35:25 2015 -0500

    Merge topic 'try_compile-shorter-names' into next
    
    f3e9eeed try_compile: Use shorter test executable name with consistent length


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=f3e9eeedf43f783c02b2a2a10fc0e632eaf7cfd0
commit f3e9eeedf43f783c02b2a2a10fc0e632eaf7cfd0
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Tue Feb 10 10:21:55 2015 -0500
Commit:     Brad King <brad.king at kitware.com>
CommitDate: Tue Feb 10 10:28:41 2015 -0500

    try_compile: Use shorter test executable name with consistent length
    
    Since commit v2.8.8~176^2 (try_compile: Use random executable file name,
    2012-02-13) the length of the test executable name in generated
    try_compile projects has been longer and unpredictable.  With Visual
    Studio on windows, the tools try to create paths like:
    
     CMakeFiles/CMakeTmp/$tgt.dir/Debug/$tgt.tlog/$tgt.lastbuildstate
    
    With the target name repeated up to 3 times, we must make it short and
    of consistent length to avoid overrunning the 260 character limit
    imposed by VS tools.

diff --git a/Source/cmCoreTryCompile.cxx b/Source/cmCoreTryCompile.cxx
index c414553..d9369e6 100644
--- a/Source/cmCoreTryCompile.cxx
+++ b/Source/cmCoreTryCompile.cxx
@@ -383,8 +383,8 @@ int cmCoreTryCompile::TryCompileCode(std::vector<std::string> const& argv)
 
     /* Use a random file name to avoid rapid creation and deletion
        of the same executable name (some filesystems fail on that).  */
-    sprintf(targetNameBuf, "cmTryCompileExec%u",
-            cmSystemTools::RandomSeed());
+    sprintf(targetNameBuf, "cmTC_%05x",
+            cmSystemTools::RandomSeed() & 0xFFFFF);
     targetName = targetNameBuf;
 
     if (!targets.empty())

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

Summary of changes:
 Source/cmCoreTryCompile.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list