Non-compatible Ant task execution order

When running ant builds in gradle, the execution order may be different from native ant. This may break the output of ant builds. It is a breaking change, that reduces the usefulness of having Ant inside of Gradle.

I think at the minimum, a notice should be put in the documentation. This could cause silent corruption of ant builds.

build.xml:

<project basedir="." default="all">
     <target name="a">
      <echo>target a</echo>
   </target>
     <target name="b">
      <echo>target b</echo>
   </target>
     <target name="c">
      <echo>target c</echo>
   </target>
     <target name="all" depends="b,c,a" />
  </project>

build.gradle:

ant.importBuild 'build.xml'

Ant OUTPUT:

$ ant
 Buildfile: /home/pcm/gradle-ant/build.xml
  b:
     [echo] target b
  c:
     [echo] target c
  a:
     [echo] target a
  all:
  BUILD SUCCESSFUL
Total time: 0 seconds

Gradle OUTPUT:

$ gradle
all
:a
[ant:echo] target a
:b
[ant:echo] target b
:c
[ant:echo] target c
:all
  BUILD SUCCESSFUL
  Total time: 1.43 secs