felix-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Elliot Huntington <elliot.hunting...@gmail.com>
Subject How to make non-osgi jar available to felix launcher?
Date Mon, 11 Nov 2013 17:59:42 GMT
I'm launching the felix launcher with:

$ java -jar bin/felix.jar

The application contains:

app/
app/bin/felix.jar
app/bundle/*.jar
app/conf/config.properties

This application uses JavaFX so I did:

$ mv $JAVA_HOME/jre/lib/jfxrt.jar $JAVA_HOME/jre/lib/ext/

And then I set the property org.osgi.framework.system.packages.extra to
expose the javafx.* packages to the container. This works appropriately
because the jfxrt.jar file is on the system classpath.

Now I have a 3rd party jar which is not an OSGi bundle. I used the bnd tool
to modify the manifest to contain the needed OSGi meta-data. I verified
that it exports the specific packages that I need, placed the jar in the
app/bundle directory, and I verified that my bundle imports the same needed
packages. I still get a ClassNotFoundException.

Is there a way, with the default launcher in felix.jar, to specify some
directory that contains non osgi jar files that can be used on the
classpath similar to what is being done with the combination of
$JAVA_HOME/jre/lib/ext/ and the org.osgi.framework.system.packages.extra
property?

I know this is NOT the recommended (or best) way to do this, but I haven't
been able to figure out how to make it work the right way.

If it helps, I created a project on GitHub that demonstrates the problem
I'm having. It is located at
https://github.com/axiopisty/scala-actors-javafx-osgi-demo.

Thanks,
Elliot

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message