This is the mail archive of the kawa@sources.redhat.com mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: version and packaging issues


"Robert D. Skeels" <robertd@synchrotech.com> writes:

> When using the current .jar files on non-Unix-like platforms, Kawa reports
> back 1.6.68 when (scheme-implementation-version) is called. This is true
> when using the kawa-1.6.70.jar file from the Kawa ftp site, or when I
> compile and package kawa-1.6.71.jar myself. Both report the correct versions
> when run on the Unix box.
> 
> I checked the source for the getVersion() function in Kawa.Version class and
> it has the correct return string for both 1.6.70 and 1.6.71. I am wondering
> if the Scheme function (scheme-implementation-version) calls the Java
> getVersion() function directly?

Yes, but it does a constant-fold.  You can see where a Scheme builtin is
defined by searching kawa/standard/Scheme.java.  That refers you to the
kawa.lib.misc.  Looking at kawa/lib/misc.scm we see:

(define (scheme-implementation-version)
  (constant-fold
   (primitive-constructor <string> (<java.lang.String>))
   (constant-fold (primitive-static-method <kawa.Version> "getVersion"
					   <java.lang.String> ()))))

So we do see that it is kawa.Version.getVersion that is being called.
But because of the constant-fold, it is being called at compile-time.
You can see this if you disassemble kawa.lib.misc.  Doing so will give
you the actual version string returned by scheme-immplementation-version.

> If so, then why doesn't it report back the
> correct version? 

That I don't know.  Perhaps you need to recompile kawa.lib.misc?
-- 
	--Per Bothner
per@bothner.com   http://www.bothner.com/~per/

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]