ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Paris" <rpj...@hotmail.com>
Subject Why is Java task not adding my classpath ref unless fork="yes"?
Date Wed, 28 Jan 2004 17:26:34 GMT
I have the following in my build.xml:

<path id="project.java.classpath">
    <fileset dir="${dir.deploy}">
        <include name="*.jar" />
    </fileset>
</path>

<target name="run" depends="jar">
    <java classname="com.mycompany.plaf.test.TestLAF">
        <classpath refid="project.java.classpath" />
    </java>
</target>

In the TestLAF class, I print out the java.class.path system property and it 
doesn't include jars in the "deploy" folder. Can anyone tell me what I'm 
doing wrong? The other weird thing is that the class 
"com.mycompany.plaf.test.TestLAF" is in that same jar and when I use 
"-debug" it prints that it loads that class from that jar file but it still 
cannot find any other class in the jarfile and the java.class.path does not 
include the jar file. I'm completely stumped!

BTW, it does add the proper classpath ONLY if I use fork="yes".

Thanks,

Robert

_________________________________________________________________
High-speed usersóbe more efficient online with the new MSN Premium Internet 
Software. http://join.msn.com/?pgmarket=en-us&page=byoa/prem&ST=1


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


Mime
View raw message