1
0
Fork 0
mirror of https://github.com/rbenv/ruby-build.git synced 2025-02-16 10:11:13 +01:00

Require Java 7 for jruby-9000-dev.

This commit is contained in:
Chris Seaton 2014-02-10 15:22:21 +00:00
parent c78eb9db6c
commit 484782aa89
2 changed files with 18 additions and 0 deletions
bin
share/ruby-build

View file

@ -576,6 +576,23 @@ fix_rbx_irb() {
true
}
require_java7() {
local version=`java -version 2>&1`
if [ $? -eq 0 ]
then
if [[ $version == *1.[78]* ]]
then
return 0
else
echo "jruby-9000-dev requires Java 7 - please install a 1.7 compatible JRE, or ensure it is on your path"
return 1
fi
else
echo "Couldn't execute Java - please install a 1.7 compatible JRE, or ensure it is on your path"
return 1
fi
}
require_gcc() {
local gcc="$(locate_gcc || true)"

View file

@ -1 +1,2 @@
require_java7
install_package "jruby-9000.dev" "http://ci.jruby.org/snapshots/master/jruby-dist-9000.dev-bin.tar.gz" jruby