From 93c55ec1421a2cf43dbcaf9afd0528c8dda42de5 Mon Sep 17 00:00:00 2001 From: Alex Neundorf Date: Thu, 5 Jan 2012 21:53:02 +0100 Subject: FindRuby: fix usage of RUBY_VERSION_MAJOR (#12172) Alex --- Modules/FindRuby.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Modules/FindRuby.cmake') diff --git a/Modules/FindRuby.cmake b/Modules/FindRuby.cmake index ae2ea2e330..402568b15f 100644 --- a/Modules/FindRuby.cmake +++ b/Modules/FindRuby.cmake @@ -60,7 +60,7 @@ ENDIF("${Ruby_FIND_VERSION_SHORT_NODOT}" VERSION_LESS "19") FIND_PROGRAM(RUBY_EXECUTABLE NAMES ${_RUBY_POSSIBLE_EXECUTABLE_NAMES}) -IF(RUBY_EXECUTABLE AND NOT RUBY_MAJOR_VERSION) +IF(RUBY_EXECUTABLE AND NOT RUBY_VERSION_MAJOR) # query the ruby version EXECUTE_PROCESS(COMMAND ${RUBY_EXECUTABLE} -r rbconfig -e "print Config::CONFIG['MAJOR']" OUTPUT_VARIABLE RUBY_VERSION_MAJOR) @@ -135,7 +135,7 @@ IF(RUBY_EXECUTABLE AND NOT RUBY_MAJOR_VERSION) RUBY_VERSION_MINOR RUBY_VERSION_PATCH ) -ENDIF(RUBY_EXECUTABLE AND NOT RUBY_MAJOR_VERSION) +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. -- cgit v1.2.1