首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >linux上的ant-contrib安装失败

linux上的ant-contrib安装失败
EN

Stack Overflow用户
提问于 2013-05-17 19:56:59
回答 1查看 872关注 0票数 1

我想使用'ant-contrib',但我不能使用它。我试着用了3种方法,但没有成功。

代码语言:javascript
复制
Apache Ant(TM) version 1.8.2

 echo $ANT_HOME
 /usr/share/ant

./usr/share/ant/lib/ant-contrib-1.0b2.jar
./usr/share/java/ant/ant-contrib-1.0b2.jar
./usr/share/java/ant.jar

*1.*
<taskdef resource="net/sf/antcontrib/antcontrib.properties" />

RESULT:
Buildfile: /home/username/build.xml
[taskdef] Could not load definitions from resource net/sf/antcontrib           
/antcontrib.properties. It could not be found.

*2.*
<taskdef resource="net/sf/antcontrib/antlib.xml"/>

RESULT:
Buildfile: /home/username/build.xml
[taskdef] Could not load definitions from resource net/sf/antcontrib/antlib.xml.        It     could not be found.


 *3.* build.xml in my home, and ant-contrib in home/lib
 <classpath id="contrib.classpath.ref">
            <fileset dir="${basedir}/lib"/>
    </classpath>

    <taskdef resource="net/sf/antcontrib/antcontrib.properties" classpathref="contrib.classpath.ref"/>

 RESULT:
 Buildfile: /home/username/build.xml:2: Problem: failed to create task or type  classpath
 Cause: The name is undefined.
 Action: Check the spelling.

我不知道其他的解决方案,我可以遍历一个文件集/自定义列表,一个接一个地对它们做一些事情。这就是为什么它对我很重要。老实说,为什么没有清晰的文档?

EN

回答 1

Stack Overflow用户

发布于 2013-05-18 13:59:28

问题是上面提到的严。我的身体里有更多的蚂蚁。

总而言之,我删除了它们,用一个全新下载的ant重新尝试了我的构建xml。什么不在路径上,并从它所在的目录开始。

我知道这不是最好的设置,但我可以尝试我想要的,解决正确的设置只是时间问题。

感谢你们的时间和努力。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/16608415

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档