ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject AW: Error in <jar> found?
Date Thu, 23 Jan 2003 09:03:27 GMT

an empty zip is not allowed therefore the check against "zip".
Because of the existence of a jar can´t be empty and therefore
no check 
against "jar".
Maybe a hint would be useful:
    public void execute() throws BuildException {
        checkCondition(); // Hook for Subclasses
    checkCondition() {
        if (baseDir == null && filesets.size() == 0
            && groupfilesets.size() == 0 && "jar".equals(archiveType)) {
            log("basedir attribute not set - your jar could only contain the", Project.MSG_VERBOSE);

(not tested, only a thought)

Jan Matèrne

-----Ursprüngliche Nachricht-----
Von: Stefan Bodewig []
Gesendet am: Donnerstag, 23. Januar 2003 09:57
Betreff: Re: Error in <jar> found?

On Thu, 23 Jan 2003, Jan Materne <> wrote:

> Maybe you can set the basedir to the current directory (and excludes
> the archive itself).

I think that would be wrong (as it violated the contract for Zip), the
correct solution is that Jar has to check for the manifest itself.

The reason for "zip".equals(...) is that it would be perfectly legal
to construct a jar file with only a manifest specified using a nested
<manifest> in it.


To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message