jruby bash script fails with bash 2.03 (Solaris 8)
--------------------------------------------------
Key: JRUBY-1671
URL: http://jira.codehaus.org/browse/JRUBY-1671
Project: JRuby
Issue Type: Improvement
Components: Interpreter
Environment: bash 2.03
tested in Solaris 8
Reporter: Javier Vidal Postigo
Priority: Minor
jruby bash script fails with bash 2.03:
$ jruby -v
/export/home/cacti/jruby-1.1b1/bin/jruby: while: command not found
/export/home/cacti/jruby-1.1b1/bin/jruby: line 119: syntax error near
unexpected token `do'
/export/home/cacti/jruby-1.1b1/bin/jruby: line 119: `do'
The problem are these two empty array declarations:
java_args=()
ruby_args=()
This seems to be a bash 2.03 bug, but I haven't found any information reporting
it.
I have found a workaround to this issue. Empty arrays can be declared this way:
declare -a java_args
declare -a ruby_args
So now jruby script works fine in Solaris 8.
Note 1: bash-2.03 is the default bash shell in Solaris 8
Note 2: I don't know if this diff can be used as a patch:
$ diff jruby jruby.orig
116,117c116,117
< declare -a java_args
< declare -a ruby_args
---
> java_args=()
> ruby_args=()
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email