Hi,

the fix for 22863 which allows <move>'s file attribute to point to a
directory breaks the tomcat-dbcp build in Gump:
<http://brutus.apache.org/gump/public/jakarta-tomcat-5/jakarta-tomcat-dbcp/gump_work/build_jakarta-tomcat-5_jakarta-tomcat-dbcp.html>

The build does this:

  <move todir="${tomcat-dbcp.home}/src/java/org/apache/tomcat/dbcp">
    <fileset dir="${tomcat-dbcp.home}/src/java/org/apache/commons" />
  </move>

where ${tomcat-dbcp.home}/src/java/org/apache/tomcat/dbcp exists prior
to invoking the task.  This assumes that all files and directories
from below ${tomcat-dbcp.home}/src/java/org/apache/commons will get
moved and it works for all older versions of Ant.

Since the fileset matches all files and directories and neither of
them is present in the dbcp directory before the move (in fact it is
empty), ${tomcat-dbcp.home}/src/java/org/apache/commons is added to
completeDirMap and renameFile is tried.

With the fix for 22863 renameFile has been changed to throw a
BuildException if we try to rename a directory to an existing
directory (thus the failure above) while the old code would simply
return false and make Ant take the hard route of copying all files
individually.

It would be easy to revert the changes made to renameFile around line
385 - and I've confirmed that it will make the Tomcat build pass again
- but I'm afraid I'm missing something.  In particular since it will
break testCompleteDirectoryMoveFileToDirWithExistingDir in MoveTest.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to