Hmm... one way you could accomplish this would to be import the build
file as a resource.
Take a look at the Import task docs in the Ant manual - specifically the
section under: "any resource or resource collection." This was added in
Ant 1.8.0. It seems similar enough to what you're looking to
If I read the source of Ants main class [1] I would think, that the buildfile
must be a real file on the file system. It cannot be run from the classpath.
What do you expect from bundling the buildfile in a jar?
A workaround is using a "launcher buildfile" which extracts the content oft he
jar