mirror of
https://github.com/rkd77/elinks.git
synced 2025-02-02 15:09:23 -05:00
Revisit Ruby version checking fix
The version checking was recently reworked in commit 14d5ff3b1722ca8df12fbc2739a39a18ebdd4ee6, however use of 'puts' is wrong because it returns nil and thus always causes the check to exit with code 1. The issue was brought up by dalias. Acked on IRC by Thomas Adam.
This commit is contained in:
parent
44537de0c4
commit
ca7a70b243
@ -32,7 +32,7 @@ if test "$CONFIG_SCRIPTING_RUBY" = "yes"; then
|
||||
if test "$CONFIG_SCRIPTING_RUBY" != "no"; then
|
||||
|
||||
AC_MSG_CHECKING(Ruby version)
|
||||
if $CONFIG_SCRIPTING_RUBY -e 'puts "#{VERSION rescue RUBY_VERSION}" >= "1.6.0" or exit 1' >/dev/null 2>/dev/null; then
|
||||
if $CONFIG_SCRIPTING_RUBY -e 'exit((VERSION or RUBY_VERSION) >= "1.6.0")' >/dev/null 2>/dev/null; then
|
||||
ruby_version=`$CONFIG_SCRIPTING_RUBY -e 'puts "#{VERSION rescue RUBY_VERSION}"'`
|
||||
AC_MSG_RESULT($ruby_version)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user