Skip to Main Content

Force JRE to use CLASS files instead of JAR files

scampsdNov 19 2014 — edited Dec 5 2014


I am working on a product, based on Java technology.

This product has previously been compiled into a *.jar file.

When I change a *.java file, the corresponding *.class file gets created (not the *.jar) file.

I then put the *.class file in the same directory of the *.jar file, and it seems that normally the JRE knows somehow that he needs to use the *.class file instead of the one, embedded in the *.jar file.

However on my system this seems not to work.

I believe it has something to do with the CLASSPATH variable, but I have no idea how to work with this.

Does anybody has an idea on how to tell JRE that it can take a *.jar file for executing a program, but in case *.class files are found in the same directory, those ones need to be used instead of the ones, embedded in the *.jar file?


Post Details
Added on Nov 19 2014