harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pavel Pervov <pmcfi...@gmail.com>
Subject Re: about java -version issue for harmony java launcher
Date Thu, 19 Mar 2009 07:33:29 GMT
Deven,

I suppose it is very easy to check RI's behaviour WRT -version option
for JNI_CreateJavaVM isn't it?

WBR,
   Pavel.

On Thu, Mar 19, 2009 at 9:05 AM, Deven You <devyoudw@gmail.com> wrote:
>  Harmony java launcher  "java -version" command can not work with IBM J9
> VM26 . The error result is as below:
>
>  ../jres/see/bin/java -version
> Apache Harmony Launcher : (c) Copyright 1991, 2008 The Apache Software
> Foundation or its licensors, as applicable.
> JVMJ9VM007E Command-line option unrecognised: -version
> HMYEXEL062E Internal VM error: Failed to create Java VM
> FAILED to invoke JVM
> This issue occurs on both linux and windows x86 platform.
>
>  I find our laucher just invoke the mothod JNI_CreateJavaVM()  of  vm which
> on j9 vm does not deal with -version option according to JNI Specification.
> the specification says:
> "All Java virtual machine implementations must recognize the following set
> of standard options:  ..."
> it lists:
>  -D<name><value>
>  -verbose
>  vfprintf
>  exit
>  abort
>
> It then goes on to stay:
> "In addition, virtual machine implementations may support their own set of
> implementation-dependent option strings.  Implementation-dependent option
> strings must begin with "-X" or an underscore."
> Any other option is non-standard.
>
> but for DRLVM, seems its JNI_CreateJavaVM() does not comply with JNI
> Specification and support -version option.the result is below:
>
> Apache Harmony Launcher : (c) Copyright 1991, 2008 The Apache Software
> Foundation or its licensors, as applicable.
> java version "1.5.0"
> pre-alpha : not complete or compatible
> svn = r745401, (Feb 18 2009), Windows/ia32/msvc 1310, release build
> http://harmony.apache.org.
> but there is still no vm version info.
>
> I suggest our java launcher should not pass -version or other non-standarad
> options  to vm interface JNI_CreateJavaVM(), instead we should make a
> general solution to deal with them, maybe call certain methods in jre tool
> package. so that  our java laucher can work well on different vms.
>

Mime
View raw message