File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Ant, Maven and Other Build Tools and the fly likes What is the difference between two path task code? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of Practical Unit Testing with TestNG and Mockito this week in the Testing forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Reply Bookmark "What is the difference between two path task code?" Watch "What is the difference between two path task code?" New topic
Author

What is the difference between two path task code?

Ayse Muge
Greenhorn

Joined: Jul 22, 2004
Posts: 5
Hi all,

In source folder, there are java files to compile. They need to use some jar files I defined under the lib folder.

what is the difference between 2 code? I think there is no difference but first one is ok,it works; but second one is not working. Instead of writing jar files name one by one, I define all files in one step in second code for javac task which jar files it needs to use.Ignore my folder values there is no problem. My problem is how can I define my all jar files in one step?

Any suggestion?
Thnx


<path id="designer.path">
<pathelement location="lib/cs_mdi.jar"/>
<pathelement location="lib/csfc.jar"/>
<pathelement location="lib/debugger.jar"/>
<pathelement location="lib/jbcl.jar"/>
<pathelement location="lib/lf.jar"/>
<pathelement location="lib/UID.jar"/>
<pathelement location="lib/xerces.jar"/>
<pathelement location="lib/JavaRenderer.jar"/>
</path>

----------------------------------------------------------------

<path id="designer.path">
<pathelement location="lib/*.jar"/>
</path>


the following code is in javac task. I used classpathref attribute in here:

<target name="build" depends="checkpack">
<javac srcdir="${LclFldrSrc}" destdir="${LclFldrDest}" classpathref="designer.path"/>
</target>

Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
I'm not sure if pathelement supports all of the patterns that something like fileset or patternset would. Why not try using a fileset instead?

[ July 22, 2004: Message edited by: Dirk Schreckmann ]

[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
 
 
subject: What is the difference between two path task code?
 
Threads others viewed
ServletTestCase::request is not accessible my test class, which extends jspTestCase.
ANT Javac File based classpath?
Classpath problems(?)
Need help with Ant
Ant: earExport is not working with Jdk 1.4
IntelliJ Java IDE