Ant supplies all the neccesary tasks to do this. Just consider the constituent steps you need to perform to package the app (javac, move/copy, jar etc.) and check the Ant docs. There will be a task for each. Also there will be plenty of examples out there already - a whole bunch of open source projetcs use ant, and their build files are publically avaliable to view.