[Cmake-commits] CMake branch, next, updated. v2.8.7-2253-gda1c1c3

Rolf Eike Beer eike at sf-mail.de
Wed Jan 25 11:41:30 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  da1c1c3067df653dbc51fb6d12ae00aebe40ec72 (commit)
       via  393c2e14fbb60c18d90d82383d89a6cba59b57fe (commit)
      from  86edc3ce1d5cb2e3cd1bd40c81cb0d4254ebc6b3 (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=da1c1c3067df653dbc51fb6d12ae00aebe40ec72
commit da1c1c3067df653dbc51fb6d12ae00aebe40ec72
Merge: 86edc3c 393c2e1
Author:     Rolf Eike Beer <eike at sf-mail.de>
AuthorDate: Wed Jan 25 11:41:28 2012 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Wed Jan 25 11:41:28 2012 -0500

    Merge topic 'findruby-no-dummy-version' into next
    
    393c2e1 FindRuby: do not blindly set version to 1.8.0


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=393c2e14fbb60c18d90d82383d89a6cba59b57fe
commit 393c2e14fbb60c18d90d82383d89a6cba59b57fe
Author:     Rolf Eike Beer <eike at sf-mail.de>
AuthorDate: Wed Jan 25 17:26:43 2012 +0100
Commit:     Rolf Eike Beer <eike at sf-mail.de>
CommitDate: Wed Jan 25 17:34:09 2012 +0100

    FindRuby: do not blindly set version to 1.8.0
    
    RUBY_VERSION was always set, even if no RUBY_EXECUTABLE was found. While it
    may make sense to assume a default version if we can't execute the binary, it
    certainly doesn't make sense to report a version if there is no executable at
    all.

diff --git a/Modules/FindRuby.cmake b/Modules/FindRuby.cmake
index 5d6c98a..3fd2ded 100644
--- a/Modules/FindRuby.cmake
+++ b/Modules/FindRuby.cmake
@@ -139,7 +139,7 @@ ENDIF(RUBY_EXECUTABLE  AND NOT  RUBY_VERSION_MAJOR)
 
 # In case RUBY_EXECUTABLE could not be executed (e.g. cross compiling)
 # try to detect which version we found. This is not too good.
-IF(NOT RUBY_VERSION_MAJOR)
+IF(RUBY_EXECUTABLE AND NOT RUBY_VERSION_MAJOR)
    # by default assume 1.8.0
    SET(RUBY_VERSION_MAJOR 1)
    SET(RUBY_VERSION_MINOR 8)
@@ -149,8 +149,7 @@ IF(NOT RUBY_VERSION_MAJOR)
       SET(RUBY_VERSION_MAJOR 1)
       SET(RUBY_VERSION_MINOR 9)
    ENDIF(${RUBY_EXECUTABLE} MATCHES "ruby1.?9"  OR  RUBY_HDR_DIR)
-ENDIF(NOT RUBY_VERSION_MAJOR)
-
+ENDIF(RUBY_EXECUTABLE AND NOT RUBY_VERSION_MAJOR)
 
 SET(RUBY_VERSION "${RUBY_VERSION_MAJOR}.${RUBY_VERSION_MINOR}.${RUBY_VERSION_PATCH}")
 SET(_RUBY_VERSION_SHORT "${RUBY_VERSION_MAJOR}.${RUBY_VERSION_MINOR}")

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

Summary of changes:
 Modules/FindRuby.cmake |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list