javah 错误

错误:无法访问 com.myproject.FirstNDKProjectActivity
未找到 com.myproject.FirstNDKProjectActivity 的类文件
javadoc: 错误 - 找不到类 com.myproject.FirstNDKProjectActivity。
Error: 未在命令行中指定任何类。请尝试使用 -help。

总有以上错误,尝试下面的方法:

The ant part of the Android build system actually places the class files in bin/classes. So you need to have $PROJECT_DIRECTORY/bin/classes on the javah classpath. For example, from the src directory you could run:

$PROJECT_DIRECTORY/src$ javah -classpath ../bin/classes bt.nativeclient.BtnativeActivity

This assumes that you've compiled your Java code to the corresponding class files first. You can check by seeing what is in the bin/classes directory - it should contain the bt directory, which is the top of your package name.

应该这样:

 

~/android_workspace/FirstNDKProject/src$ javah -classpath ../bin/classes/ com.myproject.FirstNDKProjectActivity

生成头文件就在src下面!

OK!
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值