Skip to content

Windows: jruby appear to pass unknown java option when JRUBY_HOME is set #10

Open

Description

@headius

(From jruby/jruby#3610 by @rob99)

C:\scripts>set JRUBY_HOME=c:\downloads\jruby-9.0.4.0
C:\scripts>jruby -v
Usage: java [-options] class [args...](to execute a class)
or java [-options] -jar jarfile [args...](to execute a jar file)
where options include:
-d32 use a 32-bit data model if available
-d64 use a 64-bit data model if available

snip...

C:\scripts>set JRUBY_HOME=
C:\NotBackedUp\brownr12\scripts>jruby -v
jruby 9.0.4.0 (2.2.2) 2015-11-12 b9fb7aa Java HotSpot(TM) 64-Bit Server VM 24.71-b01 on 1.7.0_71-b14 +jit [Windows 7-amd64]

The problem seems to relate to the trailing \ character in the path. If you specify the same JRUBY_HOME without the trailing slash, it works correctly. This behavior only appears to affect Windows (or perhaps only systems with backslash as path delimiter).

@enebo had a theory that it may be causing problems with C string escapes.

I have no theory.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions