Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Aug 2009 18:58:09 -0500
From:      Lane Holcombe <lane@joeandlane.com>
To:        freebsd-java@freebsd.org
Subject:   ScriptEngineManager.getEngineFactories() is empty List<>
Message-ID:  <1250207889.16044.25.camel@lholcombe-desktop>

next in thread | raw e-mail | index | archive | help
Hi,

Sorry if this was asked before, but htdig did not yield any results for
my queries.

I'm on 7.2-STABLE, trying to use jdk6

I've installed each of these jdk's, trying to find one which has the
rhino script engine bundled:  jdk16, diablo-jdk16, linux-sun-jdk16, and
openjdk6.

No such luck.  Each call to 
(new ScriptEngineManager()).getEngineFactories() yields and empty list
(Note: that is pseudo-code for brevity.  My call to getEngineFactories()
works on ubuntu, xp, etc., just not on freebsd).

I see in the source below /usr/ports/java/jdk16/work/... that the Rhino
engine is included in the port, but it is apparently NOT included in
rt.jar when the port is built.

Sun claims that scripting engines can be "plugged in," but I've not
found a single line of documentation that explains how I would do this.

Is there a build-time switch I can use to include rhino scripting when
rt.jar is built?  Or a run-time switch that would cause java to expose
the contents of js.jar to the ScriptEngineManager?

I can get rhino to work as a command-line utility by installing
ports/lang/rhino, but I want to use the scriptengine in a server-based
project.

Thanks for your attention.

lane




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1250207889.16044.25.camel>