it is likely that some of your native methods are removed during Proguard shrink
phase, because they aren't called by the Java code. Check out Proguard's output
in project/obf/usage.txt.
You may either remove these methods if they aren't actually needed. Or tell
Proguard to preserve them no matter what, by using -keepclasseswithmembers
(instead of -keepclasseswithmembernames).
Eg:
-keepclasseswithmembers class * {
native <methods>;
}
Olivier
--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/android-ndk?hl=en.
> On Sun, Nov 14, 2010 at 12:26 AM, GJTorikian <gjtor...@gmail.com
> <mailto:gjtor...@gmail.com>> wrote:
>
> -keepclasseswithmembernames class * {
> native <methods>;
> }
Great chances are that some of your native declarations are removed during the
shrinking phase, because not called by Java code.
Use this instead:
-keepclasseswithmembers class * {
native <methods>;
}
Ref: http://proguard.sourceforge.net/manual/usage.html#keepoptions
--
Olivier
It sounds like your problem happens in JNI_OnLoad(). Do you define it?
If yes, what do you do in there?
Olivier