Alan Kimball
Alan Kimball

Reputation: 21

Unable to debug android app on target

I am trying to create a new app with Eclipse. Things seem to work fine if I run through the emulator, but I cannot deploy it to my phone.

I have an original Motorola Droid, rooted running Gingerbread.

In the console, I get:

    [2011-05-30 15:13:30 - MapsDemo] ------------------------------
    [2011-05-30 15:13:30 - MapsDemo] Android Launch!
    [2011-05-30 15:13:30 - MapsDemo] adb is running normally.
    [2011-05-30 15:13:30 - MapsDemo] Performing com.example.android.apis.MapsDemo activity launch
    [2011-05-30 15:13:30 - MapsDemo] Automatic Target Mode: Unable to detect device compatibility. Please select a target device.
    [2011-05-30 15:13:34 - MapsDemo] WARNING: Application does not specify an API level requirement!
    [2011-05-30 15:13:34 - MapsDemo] Device API version is 10 (Android
2.3.4)
    [2011-05-30 15:13:34 - MapsDemo] Uploading MapsDemo.apk onto device '0403626109009013'
    [2011-05-30 15:13:35 - MapsDemo] Installing MapsDemo.apk...
    [2011-05-30 15:13:35 - MapsDemo] Success!
    [2011-05-30 15:13:35 - MapsDemo] Starting activity com.example.android.apis.MapsDemo on device 0403626109009013

And in logcat I get:

05-30 15:30:11.922: DEBUG/AndroidRuntime(5718): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
05-30 15:30:11.922: INFO/AndroidRuntime(5718): Heap size: -Xmx40m
05-30 15:30:11.922: DEBUG/AndroidRuntime(5718): CheckJNI is OFF
05-30 15:30:11.922: WARN/dalvikvm(5718): JNI_CreateJavaVM failed
05-30 15:30:11.922: ERROR/AndroidRuntime(5718): JNI_CreateJavaVM failed
05-30 15:30:12.164: DEBUG/AndroidRuntime(5721): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
05-30 15:30:12.164: INFO/AndroidRuntime(5721): Heap size: -Xmx40m
05-30 15:30:12.164: DEBUG/AndroidRuntime(5721): CheckJNI is OFF
05-30 15:30:12.164: WARN/dalvikvm(5721): JNI_CreateJavaVM failed
05-30 15:30:12.164: ERROR/AndroidRuntime(5721): JNI_CreateJavaVM failed
05-30 15:30:12.406: DEBUG/AndroidRuntime(5725): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
05-30 15:30:12.406: INFO/AndroidRuntime(5725): Heap size: -Xmx40m
05-30 15:30:12.406: DEBUG/AndroidRuntime(5725): CheckJNI is OFF
05-30 15:30:12.406: WARN/dalvikvm(5725): JNI_CreateJavaVM failed
05-30 15:30:12.406: ERROR/AndroidRuntime(5725): JNI_CreateJavaVM failed

When I look on my phone, it doesn't seem like it is actually uploading the apk, even though it says it succeeded.

What have I done wrong? I tried searching for solutions, but I haven't had much luck...

Upvotes: 2

Views: 3419

Answers (2)

redochka
redochka

Reputation: 12829

Make sure you have the android:debuggable="true" in your AndroidManifest.xml

<application android:debuggable="true" android:name=".MyApp" android:icon="@drawable/icon" android:label="@string/app_name">

Upvotes: 0

Bryan
Bryan

Reputation: 6699

Did you enable USB Debug and install from Unknown Sources on your Android device?

Upvotes: 1

Related Questions