modify jni and lib interface