Monday, August 01, 2005

Changing the bootstrap classes in javac.exe

Sometimes we may wish to change the default bootstrap classes that are loaded by the java compiler while compiling.

javac.exe provides us with a '-bootclasspath' option for that.

I found this option useful, when I was using a older version of CORBA interfaces, which were not compatible with the "org.omg.*" CORBA interfaces in JDK 1.5. So I included the old CORBA interfaces jar file before rt.jar in the bootstrap classpath and the problem was solved.

In Eclipse, the problem was solved just by changing the order of jar files in the "Build path" menu.