Jump to content
Excelsior Forums
Sign in to follow this  

Binding and not binding classes

Recommended Posts

Hi all.

I have 2 types of jar files. Ones, like log4j, commons, jzlib and etc, that comes with BSD, GPL and etc licences. Others is our own packages that heavily reused between applications. However, due to the security reasons we would like to add our packages within th executable and leave others outside.

I am working on FC3 with jdk1.4.08.

I can create shared library objects out opf standart jars and bind other jars into the execuatble. However, due to the some licensing restrictions, I can not change standard jars such as log4j, commons and etc to *.so libraries. Thus, I would like to craete prj file where Ican expilicity say to bind some modules and do not bind others. How can I do this? I tried just put lookup for this libraries in the prj file and then in JetPackII to add them as a resources and specified them in classpath, but this does not help.

Does any one have an idea? Thank you.

Share this post

Link to post
Share on other sites


You can switch packing (binding) mode of the jar in the JET Control Panel, on the "Resources" page.

You may also try to exclude these jars from the compilation on the "Classes" page (deselect them), but note, that you will not be able to exclude classes that are used (imported) from the application classes.

If you remove these jars from the compilation completely, you may note, that some of the application classes will not be compiled. Actually, a class can be compiled only if its superclass and implementing interfaces are present and also compiled. So the application classes which extend the library classes could not be compiled and you will require to include its class files into the deployment package.

So, there are two options. Compile required part of the libraries along with application, and include library jars into package, so that not compiled library classes will be available. The second option is to completely remove the library jars from the compilation, along with the part of the application classes, and include the library and application classes into the deployment package.


Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this