ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Roger Marlow <roger_mar...@yahoo.com>
Subject Missing top level dir in jar file
Date Thu, 06 Dec 2001 15:59:39 GMT
Hello,

Using the jar task in ant.1.4.1 I am missing the top level dir
from the paths in the jar. For example if I have files and dirs like
this:-

.
./base
./base/sub
./base/sub/file1.class
./base/sub/file2.class

Then in . I run  "jar cf ajar.jar base"

then "jar tf ajar.jar" we see :-

META-INF/
META-INF/MANIFEST.MF
base/
base/sub/
base/sub/file1.class
base/sub/file2.class

(note the top level base dir is included)

However if I have an ant file that tries to create the same jar file:-

<project name="test.jar" default="do.jar" basedir=".">
    <target name="do.jar">
       <jar jarfile="ajar.jar" basedir="base"/>
    </target>
</project>

And I run "ant" then "jar tf ajar.jar" on the resulting file I get:-

META-INF/
META-INF/MANIFEST.MF
sub/
sub/file1.class
sub/file2.class

Where has the "base" dir gone? What do I have to do to get
"base" dir into the path, other than by creating a dummy
parent dir?

Regards,

Roger.


________________________________________________________________
Nokia 5510 looks weird sounds great. 
Go to http://uk.promotions.yahoo.com/nokia/ discover and win it! 
The competition ends 16 th of December 2001.

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


Mime
View raw message