
ant编译老是不成功,请教高手!! 10
我买了李刚的书《整合Struts+Hibernate+Spring应用开发详解》。现在按照步骤安装了jdk1.5,ant1.7.1,tomcat5.5.2。但是使用命令a...
我买了李刚的书《整合Struts+Hibernate+Spring应用开发详解》。现在按照步骤安装了jdk1.5 , ant 1.7.1 ,tomcat 5.5.2 。但是使用命令ant build的时候,怎么就出错了呢?控制台错误如下:
C:\Documents and Settings\Administrator>d:
D:\apache-tomcat-5.5.27\webapps\friendship\WEB-INF>ant build
Buildfile: build.xml
BUILD FAILED
Target "build" does not exist in the project "friendship".
Total time: 0 seconds
D:\apache-tomcat-5.5.27\webapps\friendship\WEB-INF> 展开
C:\Documents and Settings\Administrator>d:
D:\apache-tomcat-5.5.27\webapps\friendship\WEB-INF>ant build
Buildfile: build.xml
BUILD FAILED
Target "build" does not exist in the project "friendship".
Total time: 0 seconds
D:\apache-tomcat-5.5.27\webapps\friendship\WEB-INF> 展开
展开全部
如果你的文件名字是build.xml的话,在命令提示符中只需输入ant即可
不要用ant build
假如文件的名字不是build.xml而是其他的,比如name.xml,要运行的话就得这样输入命令 ant buildfile name.xml
不要用ant build
假如文件的名字不是build.xml而是其他的,比如name.xml,要运行的话就得这样输入命令 ant buildfile name.xml
展开全部
你的build.xml写的有问题。 friendship 这个project里面,没有还有build这个target.
你检查你的build.xml文件是否类似这样。主要的有 target name="build"这段。
<project name="friendship" basedir="." default="">
<target name="build" depends="init">
<javac ...../>
</target>
</project>
你检查你的build.xml文件是否类似这样。主要的有 target name="build"这段。
<project name="friendship" basedir="." default="">
<target name="build" depends="init">
<javac ...../>
</target>
</project>
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询