在jni.h的头文件里找到 /*
* C++ version.
*/
struct _JavaVM {
const struct JNIInvokeInterface* functions;#if defined(__cplusplus)
jint DestroyJavaVM()
{ return functions->DestroyJavaVM(this); }
jint AttachCurrentThread(JNIEnv** p_env, void* thr_args)
{ return functions->AttachCurrentThread(this, p_env, thr_args); }
jint DetachCurrentThread()
{ return functions->DetachCurrentThread(this); }
jint GetEnv(void** env, jint version)
{ return functions->GetEnv(this, env, version); }
jint AttachCurrentThreadAsDaemon(JNIEnv** p_env, void* thr_args)
{ return functions->AttachCurrentThreadAsDaemon(this, p_env, thr_args); }
#endif /*__cplusplus*/
};
这说明只支持c ++. 不支持c ?
* C++ version.
*/
struct _JavaVM {
const struct JNIInvokeInterface* functions;#if defined(__cplusplus)
jint DestroyJavaVM()
{ return functions->DestroyJavaVM(this); }
jint AttachCurrentThread(JNIEnv** p_env, void* thr_args)
{ return functions->AttachCurrentThread(this, p_env, thr_args); }
jint DetachCurrentThread()
{ return functions->DetachCurrentThread(this); }
jint GetEnv(void** env, jint version)
{ return functions->GetEnv(this, env, version); }
jint AttachCurrentThreadAsDaemon(JNIEnv** p_env, void* thr_args)
{ return functions->AttachCurrentThreadAsDaemon(this, p_env, thr_args); }
#endif /*__cplusplus*/
};
这说明只支持c ++. 不支持c ?
解决方案 »
- android相机camera 拍照瞬间显示拍的图片,怎么实现?
- 请教下 Eclipse的常用快捷键
- 有没有前辈给段使用getIntrinsicHeight()方法取得高度和宽度
- android中sqlite的问题
- 求android项目使用maven的意义?
- 电脑和手机通信socket,电脑客户端第二次接收数据的时候卡住了。。。
- Android开发的Activity生命周期问题
- 如何动态的刷新某一个activity的界面
- 一个类里面openFileOutput(fileName, MODE_PRIVATE); 总是报错!
- 导入SlidingMenu 出现"属性已经被定义"的错误
- 谁知道QQ通讯录中的那个联系人滑动时的效率问题是怎么解决的 ? 滑动时非常顺畅 .
- 请教一个问题 soundPool 音量很小
我这样操作后编译器报找不到.c文件,这是怎么?
还是楼主有另外的方法?