External JAR Android - List Incompatibilities - android

as I have read a java.lang.VerifyError in many cases hints to referencing
incompatible jar files which do not rely on the Android SDK.
My question is, whether there is a way to check,
which method calls in particular within the imported jar files are incompatible.
Is it possible to list the conflicts?
Like this I would like to check whether it is a lot of effort to make my ready made
java programme android compatible or not?
So far I only get an VerifyError and which file causes it.
But since it is a file referencing other stuff and having some code, I would like to know at which locations exactly there is the error.
EDIT:
Here you can see the log of the LogCat.
09-21 11:10:03.080: W/dalvikvm(1988): VFY: unable to resolve exception class 427 (L/codec/ContentAccessException;)
09-21 11:10:03.080: W/dalvikvm(1988): VFY: unable to find exception handler at addr 0x16
09-21 11:10:03.080: W/dalvikvm(1988): VFY: rejected Lsmb/LPP_SM;.start ()[Ljava/lang/String;
09-21 11:10:03.080: W/dalvikvm(1988): VFY: rejecting opcode 0x0d at 0x0016
09-21 11:10:03.080: W/dalvikvm(1988): VFY: rejected Lsmb/LPP_SM;.start ()[Ljava/lang/String;
09-21 11:10:03.080: W/dalvikvm(1988): Verifier rejected class Lsmb/LPP_SM;
09-21 11:10:03.080: D/AndroidRuntime(1988): Shutting down VM
09-21 11:10:03.080: W/dalvikvm(1988): threadid=1: thread exiting with uncaught exception (group=0x40a13300)
09-21 11:10:03.110: E/AndroidRuntime(1988): FATAL EXCEPTION: main
09-21 11:10:03.110: E/AndroidRuntime(1988): java.lang.VerifyError: smb/LPP_SM
09-21 11:10:03.110: E/AndroidRuntime(1988): at com.example.androidtest.DisplayMessageActivity.onCreate(DisplayMessageActivity.java:109)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.app.Activity.performCreate(Activity.java:5008)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1079)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2023)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2084)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.app.ActivityThread.access$600(ActivityThread.java:130)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1195)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.os.Handler.dispatchMessage(Handler.java:99)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.os.Looper.loop(Looper.java:137)
09-21 11:10:03.110: E/AndroidRuntime(1988): at android.app.ActivityThread.main(ActivityThread.java:4745)
09-21 11:10:03.110: E/AndroidRuntime(1988): at java.lang.reflect.Method.invokeNative(Native Method)
09-21 11:10:03.110: E/AndroidRuntime(1988): at java.lang.reflect.Method.invoke(Method.java:511)
09-21 11:10:03.110: E/AndroidRuntime(1988): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
09-21 11:10:03.110: E/AndroidRuntime(1988): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
09-21 11:10:03.110: E/AndroidRuntime(1988): at dalvik.system.NativeStart.main(Native Method)
I have asked for a list of the problematic classes or function calls.
Here I believe I can only see, that the ContentAccessException is the only issue
not compatible with Android.
At least, if I comment that part within e.g. LPP_SM the error would vanish.
But this Exception is from one of my used libraries, which I cannot change.
Could there be more conflicts?

You should be able to track the problem by carefully reading the output of "adb logcat". You should be able to see the class that could not be found as well as the class that has the bad reference. Search for WARN/dalvikvm just before the exception.
There are a few more information on this thread : Android java.lang.VerifyError?

Are you in Debug mode or using proguard for a release ? the java.lang.VerifyError is due to a different compilator version, if you have any external jars that uses android class (like View) and your target sdk is different from the used one to generate the jar. You will find the class in the Log with error. Can you provide the complete error? If your are using proguard you can prevent preverification using -dontpreverify -dontoptimizeoption.

Related

java.lang.UnsatisfiedLinkError: debugLevel

Alright, I've been going thru posts left and right trying to figure out this error.. I've managed to fix a few errors, but this is just driving me nuts.. it has almost no information.. or atleast none that makes any sense to me.
D/dalvikvm(431): Trying to load lib /data/data/com.hyperlinkup.manglerbt/lib/libventrilo_interface.so 0x405156c8
D/dalvikvm(431): Added shared lib /data/data/com.hyperlinkup.manglerbt/lib/libventrilo_interface.so 0x405156c8
D/dalvikvm(431): No JNI_OnLoad found in /data/data/com.hyperlinkup.manglerbt/lib/libventrilo_interface.so 0x405156c8, skipping init
D/dalvikvm(431): GC_EXTERNAL_ALLOC freed 61K, 53% free 2565K/5379K, external 1027K/1038K, paused 89ms
W/dalvikvm(431): No implementation found for native Lcom/hyperlinkup/manglerbt/VentriloInterface;.debuglevel (I)I
D/AndroidRuntime(431): Shutting down VM
W/dalvikvm(431): threadid=1: thread exiting with uncaught exception (group=0x40015560)
E/AndroidRuntime(431): FATAL EXCEPTION: main
E/AndroidRuntime(431): java.lang.UnsatisfiedLinkError: debuglevel
E/AndroidRuntime(431): at com.hyperlinkup.manglerbt.VentriloInterface.debuglevel(Native Method)
E/AndroidRuntime(431): at com.hyperlinkup.manglerbt.ServerList.onCreate(ServerList.java:96)
E/AndroidRuntime(431): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
E/AndroidRuntime(431): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1611)
E/AndroidRuntime(431): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1663)
E/AndroidRuntime(431): at android.app.ActivityThread.access$1500(ActivityThread.java:117)
E/AndroidRuntime(431): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:931)
E/AndroidRuntime(431): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime(431): at android.os.Looper.loop(Looper.java:123)
E/AndroidRuntime(431): at android.app.ActivityThread.main(ActivityThread.java:3683)
E/AndroidRuntime(431): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime(431): at java.lang.reflect.Method.invoke(Method.java:507)
E/AndroidRuntime(431): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
E/AndroidRuntime(431): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
E/AndroidRuntime(431): at dalvik.system.NativeStart.main(Native Method)
I/Process(431): Sending signal. PID: 431 SIG: 9
I'm trying to rework the Mangler app to use Bluetooth recording (via startBluetoothSco), but I want to make sure the original is working before incorporating the bluetooth functionality.. Any help I can get on this matter would be greatly appreciated.
edit: thinking maybe my issue is with jni_wrappers.c.. first 3 #include's are unresolved.. original build was on linux system it would appear, so it's looking for jni.h, stdint.h and ventrilo3.h
Answer is in the Logcat Stacktrace itself
No implementation found for native Lcom/hyperlinkup/manglerbt/VentriloInterface;.debuglevel (I)I D/AndroidRuntime(431): Shutting down VM
There is a Native method called debuglevel in VentriloInterface. You have not implemented that method. So, the VM throws java.lang.UnsatisfiedLinkError.

Does phonegap support Android 1.6?

I am following this guide and based on here, it says
Don't bother using older versions of Android. Use the highest SDK
target available. Phonegap will take care of backwards compatibility
for you.
So I use these targets:
Build target
Android 2.3.3
and
minimum SDK 4
and use
cordova-1.9.0.jar
but gives following error when I try to run it on Android 1.6
E/dalvikvm(200): Could not find method android.webkit.WebView.<init>, referenced from method org.apache.cordova.CordovaWebView.<init>
W/dalvikvm(200): VFY: unable to resolve direct method 285: Landroid/webkit/WebView;.<init> (Landroid/content/Context;Landroid/util/AttributeSet;IZ)V
W/dalvikvm(200): VFY: rejecting opcode 0x70 at 0x0001
W/dalvikvm(200): VFY: rejected Lorg/apache/cordova/CordovaWebView;.<init> (Landroid/content/Context;Landroid/util/AttributeSet;IZ)V
W/dalvikvm(200): Verifier rejected class Lorg/apache/cordova/CordovaWebView;
D/AndroidRuntime(200): Shutting down VM
W/dalvikvm(200): threadid=3: thread exiting with uncaught exception (group=0x4001aa28)
E/AndroidRuntime(200): Uncaught handler: thread main exiting due to uncaught exception
E/AndroidRuntime(200): java.lang.VerifyError: org.apache.cordova.CordovaWebView
E/AndroidRuntime(200): at org.apache.cordova.DroidGap.init(DroidGap.java:297)
E/AndroidRuntime(200): at org.apache.cordova.DroidGap.loadUrl(DroidGap.java:343)
E/AndroidRuntime(200): at phone.gap.test.PhonegapTestActivity.onCreate(PhonegapTestActivity.java:13)
E/AndroidRuntime(200): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1123)
E/AndroidRuntime(200): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2364)
E/AndroidRuntime(200): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2417)
E/AndroidRuntime(200): at android.app.ActivityThread.access$2100(ActivityThread.java:116)
E/AndroidRuntime(200): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1794)
E/AndroidRuntime(200): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime(200): at android.os.Looper.loop(Looper.java:123)
E/AndroidRuntime(200): at android.app.ActivityThread.main(ActivityThread.java:4203)
E/AndroidRuntime(200): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime(200): at java.lang.reflect.Method.invoke(Method.java:521)
E/AndroidRuntime(200): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:791)
E/AndroidRuntime(200): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549)
E/AndroidRuntime(200): at dalvik.system.NativeStart.main(Native Method)
However it runs well when I run it on Android 2.3.3.
Does Phonegap not support Android 1.6?
PhoneGap 1.0 removed support for Android releases before 2.1. You could use one of the 0.9.x releases with Android 1.6.
Since you are using PhoneGap 1.9, have a look at this: http://docs.phonegap.com/en/1.9.0/guide_cordova-webview_android.md.html#Embedding%20Cordova%20WebView%20on%20Android
While it would be ideal to support back to 1.6, you're only giving up <1% of your potential market reach if you move up to 2.1. Previous answers on this topic have also suggested using 2.1 (minSdkLevel="7") as your bottom end.

ClassDefNotFoundError in my own classes

I developed the project in Eclipse, then moved to IntelliJ IDEA CE 12, then moved back to the Eclipse. IDEA had converted it to eclipse project not correctly, so I imported project from existing source and added line
<nature>com.android.ide.eclipse.adt.AndroidNature</nature>
to the section. Ok, it compiles successfully, but generates a lot of strange errors for the classes written by me and then crashes.
LogCat output:
E/dalvikvm( 9673): Could not find class 'com.capsule.launcher.views.Screen', referenced from method com.capsule.launcher.views.Workspace$1.onPageSelected
W/dalvikvm( 9673): VFY: unable to resolve check-cast 458 (Lcom/capsule/launcher/views/Screen;) in Lcom/capsule/launcher/views/Workspace$1;
D/dalvikvm( 9673): VFY: replacing opcode 0x1f at 0x0010
W/dalvikvm( 9673): Unable to resolve superclass of Lcom/capsule/launcher/views/CellLayout; (346)
W/dalvikvm( 9673): Link of class 'Lcom/capsule/launcher/views/CellLayout;' failed
W/dalvikvm( 9673): Unable to resolve superclass of Lcom/capsule/launcher/views/DockBar; (455)
W/dalvikvm( 9673): Link of class 'Lcom/capsule/launcher/views/DockBar;' failed
W/dalvikvm( 9673): VFY: unable to find class referenced in signature (Lcom/capsule/launcher/views/DockBar;)
W/dalvikvm( 9673): Unable to resolve superclass of Lcom/capsule/launcher/views/CellLayout; (346)
W/dalvikvm( 9673): Link of class 'Lcom/capsule/launcher/views/CellLayout;' failed
W/dalvikvm( 9673): Unable to resolve superclass of Lcom/capsule/launcher/views/DockBar; (455)
W/dalvikvm( 9673): Link of class 'Lcom/capsule/launcher/views/DockBar;' failed
E/dalvikvm( 9673): Could not find class 'com.capsule.launcher.views.DockBar', referenced from method com.capsule.launcher.views.WorkspaceHolder.onLayout
W/dalvikvm( 9673): VFY: unable to resolve instanceof 456 (Lcom/capsule/launcher/views/DockBar;) in Lcom/capsule/launcher/views/WorkspaceHolder;
D/dalvikvm( 9673): VFY: replacing opcode 0x20 at 0x001b
D/AndroidRuntime( 9673): Shutting down VM
W/dalvikvm( 9673): threadid=1: thread exiting with uncaught exception (group=0x40d6e300)
E/AndroidRuntime( 9673): FATAL EXCEPTION: main
E/AndroidRuntime( 9673): java.lang.NoClassDefFoundError: com.capsule.launcher.views.DockBar
E/AndroidRuntime( 9673): at com.capsule.launcher.LauncherActivity.createWorkspace(LauncherActivity.java:116)
E/AndroidRuntime( 9673): at com.capsule.launcher.LauncherActivity.onCreate(LauncherActivity.java:58)
E/AndroidRuntime( 9673): at android.app.Activity.performCreate(Activity.java:5008)
E/AndroidRuntime( 9673): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1079)
E/AndroidRuntime( 9673): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2023)
E/AndroidRuntime( 9673): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2084)
E/AndroidRuntime( 9673): at android.app.ActivityThread.access$600(ActivityThread.java:130)
E/AndroidRuntime( 9673): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1195)
E/AndroidRuntime( 9673): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime( 9673): at android.os.Looper.loop(Looper.java:137)
E/AndroidRuntime( 9673): at android.app.ActivityThread.main(ActivityThread.java:4745)
E/AndroidRuntime( 9673): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime( 9673): at java.lang.reflect.Method.invoke(Method.java:511)
E/AndroidRuntime( 9673): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
E/AndroidRuntime( 9673): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
E/AndroidRuntime( 9673): at dalvik.system.NativeStart.main(Native Method)
W/ActivityManager( 301): Force finishing activity com.capsule.launcher/.LauncherActivity
D/dalvikvm( 9673): GC_CONCURRENT freed 4207K, 20% free 19381K/23943K, paused 13ms+4ms, total 52ms
W/ActivityManager( 301): Activity pause timeout for ActivityRecord{418f0cd0 com.capsule.launcher/.LauncherActivity}
D/dalvikvm( 301): GC_CONCURRENT freed 1886K, 28% free 22076K/30279K, paused 4ms+9ms, total 99ms
W/ActivityManager( 301): Activity destroy timeout for ActivityRecord{418f0cd0 com.capsule.launcher/.LauncherActivity}
D/Finsky ( 7843): [1] 5.onFinished: Installation state replication succeeded.
It worked fine in IDEA and Eclipse before!
I don't know what happend to your project, but try in Eclipse: Project--> Clean--> YourProject
Clean and Build Your Project in Eclipse.Also check in Android Manifest file ,if launcher Activity is defined correctly with its package name.
Its not a good idea to use it like this(manually) rather we can export projects from IntelliJ IDEA to Eclipse in simple steps.
please follow this standard document for the above.
http://www.jetbrains.com/idea/webhelp/exporting-intellij-idea-project-to-eclipse.html
hope this will help you.
if you use librarys in your project , try in build path add to the library export
If you do have the old working eclipse project then copy/replace all the new code and jars to it, from the IntelliJ IDEA project. Remember to copy/replace only the code and jars not the IntelliJ IDEA specific settings files.
Right click on the project which has issues and select properties.
Select the appropriate Android build (1.1, 1.5 or 1.5 with google api) and say ok.
Again right click on the project and select "Android Tools > Fix Project Properties"
Fix the imports once (if required)
Refresh the project and you should be ready to go without any manual editing
Hope this helps.

Android, class not found from imported jar file

I included a jar file in my Android project as explained in How can I use external JARs in an Android project?. With both methods described by MannyNS and Vinayak B. in this post I get the error "Could not find class 'test.libraryCalc.Calc" which is the class provided by the library. The following code illustrates the problem:
Example class provided via library: Calc.java
package test.libraryCalc;
public class Calc {
public int add(int a, int b){
return a + b;
}
}
LibraryTestActivity.java
package test.library;
import test.libraryCalc.Calc;
import android.app.Activity;
import android.os.Bundle;
public class LibraryTestActivity extends Activity {
/** Called when the activity is first created. */
#Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
Calc calc = new Calc();
int c = calc.add(3, 4);
}
}
I exported the jar file containing Calc.java to LibraryTest\libs\calc.jar
and added a reference to it using the "Add JARs..." button in the Java Build Path of LibraryTest
The library shows up in the Referenced libraries in LibraryTest
LibraryTest has no build problems but when running it on the emulator the following is shown in LogCat:
12-27 14:01:33.965: E/dalvikvm(747): Could not find class 'test.libraryCalc.Calc', referenced from method test.library.LibraryTestActivity.onCreate
12-27 14:01:33.965: W/dalvikvm(747): VFY: unable to resolve new-instance 13 (Ltest/libraryCalc/Calc;) in Ltest/library/LibraryTestActivity;
12-27 14:01:33.995: D/dalvikvm(747): VFY: replacing opcode 0x22 at 0x0008
12-27 14:01:33.995: D/dalvikvm(747): VFY: dead code 0x000a-0013 in Ltest/library/LibraryTestActivity;.onCreate (Landroid/os/Bundle;)V
12-27 14:01:34.065: D/AndroidRuntime(747): Shutting down VM
12-27 14:01:34.065: W/dalvikvm(747): threadid=1: thread exiting with uncaught exception (group=0x4001d800)
12-27 14:01:34.075: E/AndroidRuntime(747): FATAL EXCEPTION: main
12-27 14:01:34.075: E/AndroidRuntime(747): java.lang.NoClassDefFoundError: test.libraryCalc.Calc
12-27 14:01:34.075: E/AndroidRuntime(747): at test.library.LibraryTestActivity.onCreate(LibraryTestActivity.java:14)
12-27 14:01:34.075: E/AndroidRuntime(747): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
12-27 14:01:34.075: E/AndroidRuntime(747): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2627)
12-27 14:01:34.075: E/AndroidRuntime(747): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2679)
12-27 14:01:34.075: E/AndroidRuntime(747): at android.app.ActivityThread.access$2300(ActivityThread.java:125)
12-27 14:01:34.075: E/AndroidRuntime(747): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
12-27 14:01:34.075: E/AndroidRuntime(747): at android.os.Handler.dispatchMessage(Handler.java:99)
12-27 14:01:34.075: E/AndroidRuntime(747): at android.os.Looper.loop(Looper.java:123)
12-27 14:01:34.075: E/AndroidRuntime(747): at android.app.ActivityThread.main(ActivityThread.java:4627)
12-27 14:01:34.075: E/AndroidRuntime(747): at java.lang.reflect.Method.invokeNative(Native Method)
12-27 14:01:34.075: E/AndroidRuntime(747): at java.lang.reflect.Method.invoke(Method.java:521)
12-27 14:01:34.075: E/AndroidRuntime(747): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
12-27 14:01:34.075: E/AndroidRuntime(747): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
12-27 14:01:34.075: E/AndroidRuntime(747): at dalvik.system.NativeStart.main(Native Method)
12-27 14:06:34.170: I/Process(747): Sending signal. PID: 747 SIG: 9
What needs to be done to get this working? Thanks for all suggestions.
I think that the problem is that you try to add jar that contains Android code. You cannot do this. To include Android code you should create Android library. Simply create an Android project and in the project-properties Android section set that this is library project. After that you'll be able to add this library to your projects. For more about Android libraries you can read here.
Update: I've tried your code now. It works in my case. The only difference that I've made is during export of Jar I've checked Export Java source files and resources. Hope this will help you. Try it!

VerifyError, class being rejected, VFY: register1 v6 type 12, wanted 11

I'm currently working on a Wrapper for Android, Which wraps an android
apk with some DRM related stuff.. which are by the way Android
activities..
The activities i had created worked perfectly when I tested them in an
Emulator as well as on a Device.
I tried integrating it with an Application from our org's apps
store... Steps below
Extracted the apk with apktool
* Extracted class files with dex2jar
* added the class files to an Eclipse android project as classes
folder
* Added the activity def from the original app manifest to my manifest
* Compiled and Launched the app from eclipse*
Note : The activities I had created are working very fine.. They load
complete their work and try to launch the game application i was using
to Test Integration.
here's when I come across the VerifyError
11-20 22:44:07.670: W/System.err(281): at
***java.lang.Thread.run(Thread.java:1096)
11-20 22:44:08.050: W/dalvikvm(281): VFY: register1 v0 type 12, wanted
10
11-20 22:44:08.050: W/dalvikvm(281): VFY: register1 v1 type 12, wanted
10
11-20 22:44:08.050: W/dalvikvm(281): VFY: rejecting opcode 0x71 at
0x0016
11-20 22:44:08.050: W/dalvikvm(281): VFY: rejected Lao;.a (Ldh;)I
11-20 22:44:08.050: W/dalvikvm(281): Verifier rejected class Lao;***
11-20 22:44:08.060: D/AndroidRuntime(281): Shutting down VM
11-20 22:44:08.060: W/dalvikvm(281): threadid=1: thread exiting with
uncaught exception (group=0x4001d800)
11-20 22:44:08.170: E/AndroidRuntime(281): FATAL EXCEPTION: main
11-20 22:44:08.170: E/AndroidRuntime(281): java.lang.VerifyError: ao
11-20 22:44:08.170: E/AndroidRuntime(281): at
ca.jamdat.flight.trivialpursuit_hvga_eu.FlAndroidApp.onCreate(Unknown
Source)
11-20 22:44:08.170: E/AndroidRuntime(281): at
android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:
1047)
11-20 22:44:08.170: E/AndroidRuntime(281): at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
2627)
11-20 22:44:08.170: E/AndroidRuntime(281): at
android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:
2679)
11-20 22:44:08.170: E/AndroidRuntime(281): at
android.app.ActivityThread.access$2300(ActivityThread.java:125)
11-20 22:44:08.170: E/AndroidRuntime(281): at
android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
11-20 22:44:08.170: E/AndroidRuntime(281): at
android.os.Handler.dispatchMessage(Handler.java:99)
11-20 22:44:08.170: E/AndroidRuntime(281): at
android.os.Looper.loop(Looper.java:123)
11-20 22:44:08.170: E/AndroidRuntime(281): at
android.app.ActivityThread.main(ActivityThread.java:4627)
11-20 22:44:08.170: E/AndroidRuntime(281): at
java.lang.reflect.Method.invokeNative(Native Method)
11-20 22:44:08.170: E/AndroidRuntime(281): at
java.lang.reflect.Method.invoke(Method.java:521)
11-20 22:44:08.170: E/AndroidRuntime(281): at
com.android.internal.os.ZygoteInit
$MethodAndArgsCaller.run(ZygoteInit.java:868)
11-20 22:44:08.170: E/AndroidRuntime(281): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
11-20 22:44:08.170: E/AndroidRuntime(281): at
dalvik.system.NativeStart.main(Native Method)
And now I have worked around the problem..
The problem probably is dex2jar tool i used to extract the .class files from the apk (classes probably being corrupt).
I created smali files of my implementation and pasted them into smali folder of the actual application extracted using the apktool and loaded the classes using reflecion rather than directly importing them into my compiled bytecode.
Offfffffff resolved... :)

Categories

Resources