“无法加载javah”在Eclipse中出错 [英] "Can't load javah" error in Eclipse
本文介绍了“无法加载javah”在Eclipse中出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
BUILD FAILED
C:\sandbox\build-jni.xml:7:无法加载javah
这是我的build-jni。 xml文件:
< project>
< property name =binlocation =bin/>
< target name =generate-jni>
< javah destdir =$ {bin}classpath =$ {bin}>
< class name =org.example.ExecJNI/>
< / javah>
< / target>
得到这个错误?我的项目指向JDK而不是JRE
解决方案
原来我没有C:\Program Files\\ \\ Java\jdk1.7.0_15\tools.jar在我的Ant Home Entries窗口 - >首选项中。这似乎解决了这个问题。
I am trying to use the javah task in an ant build file in Eclipse and I keep getting the following error:
BUILD FAILED
C:\sandbox\build-jni.xml:7: Can't load javah
Here is my build-jni.xml file:
<project>
<property name="bin" location="bin" />
<target name="generate-jni">
<javah destdir="${bin}" classpath="${bin}">
<class name="org.example.ExecJNI" />
</javah>
</target>
Any thoughts as to why I'm getting that error? My project is pointing to the JDK and not the JRE
解决方案
Turned out I didn't have C:\Program Files\Java\jdk1.7.0_15\tools.jar in my Ant Home Entries in Window --> Preferences. That seemed to fix the problem.
这篇关于“无法加载javah”在Eclipse中出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文