Commit 2cc30828 authored by Jakub Jirutka's avatar Jakub Jirutka

community/jruby: update jruby sh script to follow upstream's jruby.bash

parent b001493f
......@@ -134,4 +134,4 @@ _mvgem() {
}
sha512sums="79f5e8674089d2f6b260e033e3ceb4571f54cb5cedbca74ba76b52dd7cb30085a8c6c2676e9be57a8ecd9e962fbcb3682a8de38e1cdde2dc6e05bd179556edc3 jruby-bin-9.2.0.0.tar.gz
f2906a0136f437eaa119eae26d93b1a8e3411bc4ccee9453debf7a5d57bce767100b36a660db42184fd8398ff258455c3f2a8ef1082c907285b48d1b9b218bc2 jruby"
6844b42f00a6cf30b9a3bad1b3a56d96f9b37750872bcd20e7a57e0dd901886e56788f5598f9cd9bb8d1483f2d85c04c0c1f3c3d7672104c37befc7247d9a520 jruby"
......@@ -3,7 +3,7 @@
#
# This jruby start script is rewrite of (poor) upstream's jruby.bash.
# It's POSIX compatible, more clean, with sensible defaults for Alpine Linux
# and without Windows, OS X and Truffle stuff. Beside that it should support
# and without Windows and OS X stuff. Beside that it should support
# all the options of jruby.bash (hopefully) with the same behaviour.
#
# -----BEGIN HELP-----
......@@ -68,6 +68,13 @@ if [ -z "$classpath" ]; then
classpath="${classpath%?}" # %? removes leading ":"
fi
java_security_egd=''
if [ -r /dev/urandom ]; then
# Non-file URL causes fallback to slow threaded SeedGenerator.
# See https://bz.apache.org/bugzilla/show_bug.cgi?id=56139
java_security_egd='file:/dev/urandom'
fi
extra_cp="${CLASSPATH:-}"
java_vm="${JAVA_VM:-"-server"}"
main_class="$MAIN_CLASS_JRUBY"
......@@ -95,6 +102,9 @@ while [ $# -gt 0 ]; do
verify_jruby='yes'
java_opts="$java_opts ${1:2}"
;;
-J-Djava.security.egd=)
java_security_egd="${1#-J-Djava.security.egd=}"
;;
-J*)
java_opts="$java_opts ${1:2}"
;;
......@@ -194,6 +204,7 @@ done
classpath="$classpath${extra_cp:+":$extra_cp"}"
java_opts="$java_opts $java_vm
${java_security_egd:+"-Djava.security.egd=$java_security_egd"}
-Djruby.home=$JRUBY_HOME
-Djruby.lib=$JRUBY_HOME/lib
-Djruby.script=jruby
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment