ant 手动打包报错: com.sun.tools.javac.Main is not on the classpPerhaps JAVA_HOME does not point to the JDK

来源:互联网 发布:软件测试需要linux 编辑:程序博客网 时间:2024/03/29 01:11

ant手动打包报错:

        javac compiler; 
com.sun.tools.javac.Main is not on the classpath. 
Perhaps JAVA_HOME does not point to the JDK. 
It is currently set to "C:\Program Files\Java\jre7"

    网上教程都是说在eclipse 配置.  但是我是打包成jar后通过ant运行的. 

     解决办法:  把jdk/lib/tools.jar 拷贝到jre7\lib\ext即可.

        

0 0