ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lars Monsees" <l.mons...@atlantisgmbh.de>
Subject RE: "A zip file cannot include itself" though exclude
Date Tue, 24 Oct 2006 07:31:57 GMT
> 
> Lars Monsees wrote:
>> Hello,
>> 
>> I get the above mentioned error on building this target:
>> 
>> 	<target name="dist" depends="generateJAR,javadoc"
>> 		description="Create distributable file"> <zip
>> 			destfile="${dist}/${zip.filename}">
<zipfileset dir="${src}"
>> 			prefix="src"/> <zipfileset dir="${basedir}"
includes="LICENSE"/>
>> 			<zipfileset dir="${dist}"
excludes="${zip.filename}"/> <!--
>> 			<zipfileset dir="${dist}" >
>> 				<exclude name="${zip.filename}"/>
>> 			</zipfileset>
>> 
>> 			<fileset dir="${dist}" >
>> 				<exclude name="${zip.filename}"/>
>> 			</fileset>
>> -->
>> 		</zip>
>> 	</target>
>> 
>> 
>> This target used to work. Honestly, I checked Eclipse´s local
>> history and there were no changes that could have caused the build
>> to fail. Besides that, I would suspect that the zipfile can be
>> created as I exclude it explicitly from itself.   
>> 
>> Of course, a workaround would be to use another output dir, but can
>> anyone explain this behaviour to me, please? 
>> btw: How do you do it in your own buildfiles regarding the location
>> of dist and zipfiles? 
>> 
>> 
>> Lars
>> 
>>
---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>> For additional commands, e-mail: user-help@ant.apache.org

> For me, I usually have a separate directory where I tar,
> zip/gzip/bzip2 my deployments.  Mostly because then I can just sftp
> or copy the contents of that directory to wherever they are needed. 
> It always "felt" cleaner to do so...
> 
> So, I breakup my directories into something like this:
> project
>   assembly
>      deploy
>      generated
>          classes
>          javacc
>      release
> 
> I am guessing you are probably compiling to the ${dist} dir?

Yes, I do. Your directory structure would be an alternative to think
about.
Funnily enough, the target now works again. And this time, I´m
absolutely sure that nothing was changed.

So, problem solved - resolution unknown


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


Mime
View raw message