For the VerifyError
part, the question Android java.lang.VerifyError? mentions the necessity to run any 3rd party JAR files through the "dx" tool that ships with the Android SDK.
The compatibility section of Android mentions:
If your application uses APIs introduced in the latest platform version but does not declare a android:minSdkVersion
attribute, then it will run properly on devices running the latest version of the platform, but not on devices running earlier versions of the platform.
So that attribute needs to be set (to 1.5 in your case), while you are compiling your project with a 2.0 SDK.
In the case of the OP nathan:
I was compiling with 2.01 while having my target and minimum sdk =3, and then testing on avd with 1.5.
This thread adds:
Pretty much all VerifyErrors
are build errors
According to this one:
Android 2.x will give you a more specific exception (NoSuchMethod
, ClassNotFound
) at the point of the failure rather than an ambiguous "VerifyError
" for the entire class. Unfortunately it's likely failing on the older versions of the OS.
Sometimes, this error is about a missing class, or missing jars, or because of some process space need to be separated with android:process=":otherProcess"
tag.
So what that means is:
Trying to catch such a VerifyError
exception is likely to fail.
See can’t catch java.lang.VerifyError
As a general rule, it's a good idea to tick the "Filter by API level" checkbox when browsing the API documentation