---
title: "(转)手动升级Eclipse的Ant插件"
author: "java-admin"
date: "2011-05-04T10:04:09Z"
tags: ["Android", "Ant", "Apache", "Eclipse", "junit"]
categories: ["编程语言"]
slug: "eclipse-ant"
draft: false
lastmod: "2011-05-04T10:04:09Z"
id: 1028028
url: "https://java-admin.iteye.com/blog/1028028"
---

(转)手动升级Eclipse的Ant插件

 

今天打包Android sdk3.0的包，提示需要ant1.80以上的版本，安装的eclipse的默认版本是1.70，网上搜了一下知道了手动升级Ant的办法

 

ant 现在最新版为 1.7.1 ，使用它可以解决运行 test-java 时出现的 \*\*\*.properties can not found 的错误，但至于 process fork faild 的问题还没解决。

手动升级过程很简单：  
1&gt; 下载最新版的ant。下面是下载地址，选择 .zip archive: apache-ant-1.7.1-bin.zip 即可  
[http://ant.apache.org/bindownload.cgi](http://ant.apache.org/bindownload.cgi)

2&gt; 手动覆盖旧版本的内容。找到插件目录：%eclipse%/plugins\\org.apache.ant\*\** 目录，把其中的内容用最新版1.7.1的去替换，  
很重要的是：1、保留META-INF文件夹；2、保留plugin.properties文件。

3&gt; 验证安装成功。若是系统环境变量里设置了 eclipse 的插件里的 ant ，则可以直接运行 ant -version 得到  
Apache Ant version 1.7.1 compiled on June 27 2008  
显示安装成功。

此时运行 test-java 是会出现很多 \[junit]... 的信息

 

[http://hi.baidu.com/7090/blog/item/4989119595615b1d7bf480db.html](http://hi.baidu.com/7090/blog/item/4989119595615b1d7bf480db.html)