Fix for release build with JNI