ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: new Launcher and CLASSPATH
Date Fri, 19 Sep 2003 12:49:18 GMT
On Fri, 19 Sep 2003, Antoine Lévy-Lambert <antoine@antbuild.com>
wrote:

> I am a bit concerned about the fact that CLASSPATH is ignored by the
> new launcher.

But the old launcher (Main) will still work the same way.

> There are lots of scripts which invoke ant as script, and set
> CLASSPATH to include different libraries.

You mean ant the wrapper script or Ant the Java program.  In the later
case, they'll use Main as their entry point and nothing is going to
break.  The former case has to be strongly documented.

> 1) change the ant startup script
> - do not include CLASSPATH in LOCALCLASSPATH
> - pass the CLASSPATH as suggested next to a -lib flag

One of the reasons for the new launcher has been a command line length
limitation.  With this approach the command line would even become
longer, I'm afraid.

> 3) testcases : would using the <java/> task with fork set to true
> and main class set to Launcher allow us to test that
> build.sysclasspath behaves as documented ?

To be honest, it never has.

build.sysclasspath=only has always included the jars from ANT_HOME/lib
if you used the wrapper script (as the script added them to the
CLASSPATH), so it has always added things to the CLASSPATH.  The new
Launcher will still do so.

> 4) does the launcher solve the problem that ant 1.5 was requiring in
> CLASSPATH some libraries which are loaded by the java runtime.

I assume you mean something like
<http://ant.apache.org/faq.html#delegating-classloader>.

The new Launcher doesn't solve that, but that we are now splitting up
optional.jar makes solution (2) a lot easier.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message