Android port version
Publié : jeu. juil. 05, 2012 12:05 am
I made an android arm port version of giac 0.9.8 whit gmp5.0.5, many test are exec well done but when I try to calculate this: integrate(1/sin(x),x) the app it crash whitout any debug information, I did add this options -frtti -fexceptions to enable dynamic_cast and let the compiler make the jni lib, as I said there is to many integrals so works fine ex: integrate(sin(x),x) result in -cos(x).
my cuestion ir how can I to debug the raize of the crash function for some operations, the adb don't show anything.
this is the jni:
jstring Java_org_giac_calculator_calc_Computer_resultFromGiac(JNIEnv* env, jobject thiz, jstring computation)
{
const char *compute = env->GetStringUTFChars(computation,0);
//string s = string(compute);
gen *g, e;
context * contextptr = 0;
context * contextptr2 = 0;
g= new gen(compute, contextptr);
e = eval(*g, contextptr2); //wen this sentence are exec, it crash only for integrate(1/sin(x),x),
__android_log_write(ANDROID_LOG_ERROR, "jni giac", e.print().c_str());
return env->NewStringUTF(e.print().c_str());
}
my cuestion ir how can I to debug the raize of the crash function for some operations, the adb don't show anything.
this is the jni:
jstring Java_org_giac_calculator_calc_Computer_resultFromGiac(JNIEnv* env, jobject thiz, jstring computation)
{
const char *compute = env->GetStringUTFChars(computation,0);
//string s = string(compute);
gen *g, e;
context * contextptr = 0;
context * contextptr2 = 0;
g= new gen(compute, contextptr);
e = eval(*g, contextptr2); //wen this sentence are exec, it crash only for integrate(1/sin(x),x),
__android_log_write(ANDROID_LOG_ERROR, "jni giac", e.print().c_str());
return env->NewStringUTF(e.print().c_str());
}