#include <jni.h>
#include <string>
#include <android/log.h>
extern "C" JNIEXPORT jstring JNICALL
Java_com_example_first_MainActivity_stringFromJNI(
JNIEnv* env,
jobject /* this */) {
std::string hello = "I am BaoHangYu";
//打印日志 日志级别 ANDROID_LOG_FATAL紧急的 tag 过滤标签
__android_log_print(ANDROID_LOG_FATAL,"testlog","test log for android");
return env->NewStringUTF(hello.c_str());
}