private int run(String[] command) throws BuildException { Execute exe = new Execute(new LogStreamHandler(this, Project.MSG_INFO, Project.MSG_WARN), null); exe.setAntRun(project); exe.setWorkingDirectory(dir); exe.setCommandline(command); try { return exe.execute(); } catch (IOException e) { throw new BuildException(e, location); } }