This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Classpath vs java.class.path


Hi,

On Wed, 2003-07-16 at 22:05, Jeff Sturm wrote:
> On Wed, 16 Jul 2003, Steve Pribyl wrote:
> >
> > System.setProperty("java.class.path","/var/netfuel/lib/mysql-connector-java-3.0.8-stable-bin.jar");
> 
> When you reach the main() method of your program, VMClassLoader has
> already been initialized and it is probably too late to redefine
> java.class.path.

In GNU Classpath we have a application/system classloader which would
make setting that system property during runtime work
(gnu/java/lang/SystemClassLoader.java). It even tries to do intelligent
caching of the paths described by the system property.

You could integrate that with libgcj and let VMClassLoader only handle
the bootstrap classpath and then have the SystemClassLoader (with
VMClassLoader as parent) handle the user classpath (and the system
property). It is somewhere on my big list of things todo when I have
time...

Cheers,

Mark


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]