Can't attach android app to device from intellij - android

I have installed ubuntu 12.04(64bit) and intelliJ 11.1.2 and Android SDK (2.3.3 with google api) and when I try to run my app on a real device from intelliJ it won't run it. Actually I can see my device in running device dialog box but I only get following error:
06-24 22:02:10.370: DEBUG/dalvikvm(12081): GC_EXPLICIT freed 204K, 38% free 5743K/9223K, external 0K/512K, paused 79ms
06-24 22:03:24.372: DEBUG/AndroidRuntime(14169): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
06-24 22:03:24.372: INFO/AndroidRuntime(14169): Heap size: -Xmx32m
06-24 22:03:24.372: DEBUG/AndroidRuntime(14169): CheckJNI is OFF
06-24 22:03:24.372: DEBUG/dalvikvm(14169): creating instr width table
06-24 22:03:24.603: DEBUG/AndroidRuntime(14169): Calling main entry com.android.commands.pm.Pm
06-24 22:03:24.663: DEBUG/dalvikvm(13730): GC_EXPLICIT freed 10K, 51% free 2686K/5379K, external 0K/0K, paused 31ms
06-24 22:03:24.663: WARN/ActivityManager(172): No content provider found for:
06-24 22:03:24.673: DEBUG/PackageParser(172): Scanning package: /data/app/vmdl-795727220.tmp
06-24 22:03:24.673: WARN/ActivityManager(172): No content provider found for:
06-24 22:03:24.793: DEBUG/dalvikvm(172): GC_EXPLICIT freed 361K, 56% free 5933K/13255K, external 35K/547K, paused 82ms
06-24 22:03:24.823: DEBUG/AndroidRuntime(14169): Shutting down VM
06-24 22:03:24.823: DEBUG/dalvikvm(14169): GC_CONCURRENT freed 215K, 71% free 306K/1024K, external 0K/0K, paused 1ms+0ms
but in other side I can run the same application using eclipse with the same android sdk configuration.
I think something is not fine with intelliJ or I mis-config something on intelliJ
my java SDK :
open-java-amd64 1.6
sun-java-1.6 32bit

Related

How can i install Adobe Air on Genymotion emulator

I'm trying to install Adobe Air (com.adobe.air) in a Genymotion emulator emulating a Galaxy S4 with android 4.4.4 and I am getting:
Failure [INSTALL_FAILED_INVALID_APK]
With adb logcat I can see:
D/AndroidRuntime( 2350):
D/AndroidRuntime( 2350): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
D/AndroidRuntime( 2350): CheckJNI is OFF
D/dalvikvm( 2350): Trying to load lib libjavacore.so 0x0
D/dalvikvm( 2350): Added shared lib libjavacore.so 0x0
D/dalvikvm( 2350): Trying to load lib libnativehelper.so 0x0
D/dalvikvm( 2350): Added shared lib libnativehelper.so 0x0
D/dalvikvm( 2350): No JNI_OnLoad found in libnativehelper.so 0x0, skipping init
D/dalvikvm( 2350): Note: class Landroid/app/ActivityManagerNative; has 179 unimplemented (abstract) methods
E/memtrack( 2350): Couldn't load memtrack module (No such file or directory)
E/android.os.Debug( 2350): failed to load memtrack module: -2
D/AndroidRuntime( 2350): Calling main entry com.android.commands.pm.Pm
W/ActivityManager( 517): No content provider found for permission revoke: file:///data/local/tmp/Adobe.AIR.v16.0.0.259_www.revdl.com.apk
W/ActivityManager( 517): No content provider found for permission revoke: file:///data/local/tmp/Adobe.AIR.v16.0.0.259_www.revdl.com.apk
I/PackageManager( 517): Copying native libraries to /data/app-lib/vmdl1421280503
D/dalvikvm( 517): GC_FOR_ALLOC freed 1626K, 20% free 10767K/13324K, paused 12ms, total 12ms
D/dalvikvm( 517): GC_FOR_ALLOC freed 309K, 17% free 11063K/13324K, paused 9ms, total 9ms
D/dalvikvm( 517): GC_FOR_ALLOC freed 1138K, 17% free 11163K/13324K, paused 11ms, total 11ms
D/dalvikvm( 517): GC_FOR_ALLOC freed 1036K, 17% free 11173K/13324K, paused 11ms, total 12ms
D/dalvikvm( 517): GC_FOR_ALLOC freed 996K, 17% free 11171K/13324K, paused 9ms, total 10ms
D/dalvikvm( 517): GC_FOR_ALLOC freed 985K, 17% free 11176K/13324K, paused 11ms, total 12ms
D/dalvikvm( 517): GC_FOR_ALLOC freed 987K, 17% free 11184K/13324K, paused 9ms, total 9ms
D/xmlCheckExt( 517): <filter>
D/xmlCheckExt( 517): pkgName = org.mozilla.firefox
D/xmlCheckExt( 517): <filter>
D/xmlCheckExt( 517): pkgName = org.mozilla.firefox_beta
D/xmlCheckExt( 517): <filter>
D/xmlCheckExt( 517): pkgName = com.good.android.gfe
D/xmlCheckExt( 517): <filter>
D/xmlCheckExt( 517): pkgName = com.adobe.air
I/PackageManager( 517): Package with second ABI is in black list: 10079com.adobe.air
W/PackageManager( 517): Package couldn't be installed in /data/app/com.adobe.air-1.apk
D/dalvikvm( 517): GC_EXPLICIT freed 1038K, 17% free 11162K/13324K, paused 1ms+1ms, total 12ms
D/AndroidRuntime( 2350): Shutting down VM
I noted the following piece in the log:
D/xmlCheckExt( 517): pkgName = com.adobe.air
I/PackageManager( 517): Package with second ABI is in black list: 10079com.adobe.air
But when I try:
adb shell pm unblock com.adobe.air
I'm getting:
Package com.adobe.air new blocked state: true
How can I unblock / remove from the blacklist Adobe Air package?
I think that you could find the apk in the sdk folder. In mac is here:
/Applications/Research In Motion/blackberry-tablet-sdk-3.2.1/runtimes/air

Android - Cordova 3.5.0 deviceready not firing after installing media plugin

This is interesting and weird issue.
First I created Cordova project locally. I'm not using Bd.
using
cordova create test com.test.project.story "Test"
Which worked successfully!
Then I added android platform, using
cordova platform add android
Worked successfully.
Then I built the project using
cordova build
Worked, again.
I opened the project from Eclipse and ran it on emulator.
Worked properly.
Then I thought of adding some plugins in my project using
cordova plugin add org.apache.cordova.file
cordova plugin add org.apache.cordova.media
Removed the android platform and added the platform again. Then built and ran the project on emulator.
The screen was stuck on Connecting to device forever.
I rechecked if I was using the correct cordova.js for android platform.
It is correct, and it says
// Platform: android
// 3.5.0
Checked ADB log and there are a lot of suspicious things going on.
D/CordovaWebViewClient( 1581): onPageFinished(file:///android_asset/www/index.html)
D/CordovaActivity( 1581): onMessage(onPageFinished,file:///android_asset/www/index.html)
D/CordovaActivity( 1581): onMessage(spinner,stop)
D/TilesManager( 1581): new EGLContext from framework: 2a1a2a10
D/GLWebViewState( 1581): Reinit shader
D/dalvikvm( 270): GC_CONCURRENT freed 322K, 46% free 9831K/17991K, paused 813ms+21ms, total 2252ms
D/dalvikvm( 270): WAIT_FOR_CONCURRENT_GC blocked 906ms
D/GLWebViewState( 1581): Reinit transferQueue
W/ApplicationContext( 1581): Unable to create external files directory
D/ ( 1581): HostConnection::get() New Host Connection established 0x4a5f8558, tid 1605
E/PluginManager( 1581): Uncaught exception from plugin
E/PluginManager( 1581): java.lang.NullPointerException
E/PluginManager( 1581): at org.apache.cordova.file.FileUtils.requestAllPaths(FileUtils.java:866)
E/PluginManager( 1581): at org.apache.cordova.file.FileUtils.execute(FileUtils.java:348)
E/PluginManager( 1581): at org.apache.cordova.CordovaPlugin.execute(CordovaPlugin.java:65)
E/PluginManager( 1581): at org.apache.cordova.PluginManager.execHelper(PluginManager.java:242)
E/PluginManager( 1581): at org.apache.cordova.PluginManager.exec(PluginManager.java:227)
E/PluginManager( 1581): at org.apache.cordova.ExposedJsApi.exec(ExposedJsApi.java:53)
E/PluginManager( 1581): at org.apache.cordova.CordovaChromeClient.onJsPrompt(CordovaChromeClient.java:227)
E/PluginManager( 1581): at android.webkit.CallbackProxy.handleMessage(CallbackProxy.java:655)
E/PluginManager( 1581): at android.os.Handler.dispatchMessage(Handler.java:99)
E/PluginManager( 1581): at android.os.Looper.loop(Looper.java:137)
E/PluginManager( 1581): at android.app.ActivityThread.main(ActivityThread.java:4745)
E/PluginManager( 1581): at java.lang.reflect.Method.invokeNative(Native Method)
E/PluginManager( 1581): at java.lang.reflect.Method.invoke(Method.java:511)
E/PluginManager( 1581): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
E/PluginManager( 1581): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
E/PluginManager( 1581): at dalvik.system.NativeStart.main(Native Method)
D/dalvikvm( 270): GC_FOR_ALLOC freed 593K, 48% free 9509K/17991K, paused 275ms, total 280ms
I/dalvikvm-heap( 270): Grow heap (frag case) to 10.559MB for 1286224-byte allocation
D/dalvikvm( 270): GC_FOR_ALLOC freed 2K, 41% free 10763K/17991K, paused 182ms, total 186ms
D/dalvikvm( 270): GC_CONCURRENT freed 61K, 38% free 11284K/17991K, paused 41ms+11ms, total 304ms
D/CordovaActivity( 1581): onMessage(spinner,stop)
D/dalvikvm( 270): GC_CONCURRENT freed 2676K, 43% free 10293K/17991K, paused 16ms+29ms, total 130ms
D/CordovaLog( 1581): file:///android_asset/www/cordova.js: Line 1154 : deviceready has not fired after 5 seconds.
I/Web Console( 1581): deviceready has not fired after 5 seconds. at file:///android_asset/www/cordova.js:1154
D/CordovaLog( 1581): file:///android_asset/www/cordova.js: Line 1147 : Channel not fired: onFileSystemPathsReady
I/Web Console( 1581): Channel not fired: onFileSystemPathsReady at file:///android_asset/www/cordova.js:1147
E/ThrottleService( 149): problem during onPollAlarm: java.lang.IllegalStateException: problem parsing stats: java.io.FileNotFoundException: /proc/net/xt_qtaguid/iface_stat_all: open failed: ENOENT (No such file or directory)
D/dalvikvm( 251): GC_CONCURRENT freed 384K, 9% free 6556K/7175K, paused 7ms+5ms, total 67ms
D/dalvikvm( 251): GC_CONCURRENT freed 384K, 9% free 6556K/7175K, paused 6ms+13ms, total 62ms
I/EventLogService( 240): Aggregate from 1403981475023 (log), 1403981475023 (data)
E/ThrottleService( 149): problem during onPollAlarm: java.lang.IllegalStateException: problem parsing stats: java.io.FileNotFoundException: /proc/net/xt_qtaguid/iface_stat_all: open failed: ENOENT (No such file or directory)
What's going on here?
UPDATE:
Works fine on iOS.
I ran into the same issue.
What worked for me was using a different version of the File plugin found here:
https://github.com/onflapp/cordova-plugin-file
Related topic: Cordova File plugin never becomes ready in Android
for me it got solved by adding cordova.js in index.html( though its not required in ripple)
<script src="cordova.js"></script>
I ran into the same and resolved using apache official dev build File plugin:
https://github.com/apache/cordova-plugin-file/
Funny enough cordova release 1.3.1-dev is more stable then official release 1.2.0 ...
By now a newer version of the file plugin has been released. You should no longer experience the issue with the updated version (and there is thus no longer a need to downgrade).
I had a similar issue. deviceReady event was not firing (ionic app on android). Worked after I removed the file plugin v1.2 and then added v1.1 instead.

Getting Fatal Signal 11 error

I am making a SIP client using PortSIP library made based on AndroidSIPSample project. I get the following error:
01-09 02:00:52.730: A/libc(750): Fatal signal 11 (SIGSEGV) at 0x00000c0d (code=1), thread 750 (ovative.innovox)
The error is not coming when I am running AndroidSIPSample project downloaded from PortSIP website.
Following is my logcat output:
01-09 02:00:47.910: D/dalvikvm(750): Trying to load lib /data/app-lib/in.innovative.innovox-2/libportsipcore.so 0x416fc190
01-09 02:00:47.981: D/dalvikvm(750): Added shared lib /data/app-lib/in.innovative.innovox-2/libportsipcore.so 0x416fc190
01-09 02:00:48.400: D/dalvikvm(750): GC_FOR_ALLOC freed 63K, 8% free 2656K/2876K, paused 81ms, total 91ms
01-09 02:00:48.432: I/dalvikvm-heap(750): Grow heap (frag case) to 5.087MB for 2457616-byte allocation
01-09 02:00:48.510: D/dalvikvm(750): GC_FOR_ALLOC freed 2K, 5% free 5053K/5280K, paused 70ms, total 70ms
01-09 02:00:49.530: D/dalvikvm(750): GC_FOR_ALLOC freed 28K, 4% free 5351K/5540K, paused 53ms, total 57ms
01-09 02:00:49.550: I/dalvikvm-heap(750): Grow heap (frag case) to 6.451MB for 1127536-byte allocation
01-09 02:00:49.630: D/dalvikvm(750): GC_FOR_ALLOC freed 1K, 3% free 6450K/6644K, paused 73ms, total 73ms
01-09 02:00:51.990: I/Choreographer(750): Skipped 167 frames! The application may be doing too much work on its main thread.
01-09 02:00:52.010: D/gralloc_goldfish(750): Emulator without GPU emulation detected.
01-09 02:00:52.730: A/libc(750): Fatal signal 11 (SIGSEGV) at 0x00000c0d (code=1), thread 750 (ovative.innovox)
I don't know what is causing it, I even put images in xhdpi drawable folder for xhdpi devices according to this answer. But still getting the error.
Please help me solve this error.
I was getting the error because I was passing wrong argument to a method of the PortSIP library, so because of that the library was throwing error.

Testing activesync with android virtual devices

I am trying to setup a android virtual device to test syncing with an activesync-server.
I followed these steps:
The problem is that syncing is not working at all, but there are no errors like connection errors ...
IMO the problem is that the virtual device only has a private IP, so the server never can send anything to it?
So I probably need some kind of forwarding, like here:
But I am not sure if that’s correct and I am also not sure which ports should be forwarded.
Here is the logcat, when I want to sync:
W/InputMethodManagerService( 148): Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy#41302038 attribute=null
I/Choreographer( 274): Skipped 41 frames! The application may be doing too much work on its main thread.
D/dalvikvm( 477): GC_CONCURRENT freed 396K, 6% free 8392K/8903K, paused 15ms+7ms, total 527ms
D/dalvikvm( 274): GC_CONCURRENT freed 360K, 11% free 9493K/10567K, paused 29ms+48ms, total 142ms
I/EAS ContactsSyncAdapterService( 477): Contact sync requested for test#example.com
D/dalvikvm( 148): GREF has increased to 601
D/dalvikvm( 477): WAIT_FOR_CONCURRENT_GC blocked 0ms
I/Choreographer( 274): Skipped 33 frames! The application may be doing too much work on its main thread.
D/dalvikvm( 477): GC_EXPLICIT freed 333K, 7% free 8355K/8903K, paused 78ms+32ms, total 1269ms
I/EAS EmailSyncAdapterService( 477): performSync
I/EAS EmailSyncAdapterService( 477): Mail sync requested for test#example.com
D/dalvikvm( 460): WAIT_FOR_CONCURRENT_GC blocked 0ms
D/dalvikvm( 460): GC_EXPLICIT freed 216K, 5% free 8483K/8839K, paused 145ms+94ms, total 914ms
D/dalvikvm( 148): WAIT_FOR_CONCURRENT_GC blocked 0ms
D/dalvikvm( 148): GC_EXPLICIT freed 510K, 7% free 11338K/12167K, paused 8ms+35ms, total 323ms
D/dalvikvm( 274): GC_CONCURRENT freed 415K, 11% free 9486K/10567K, paused 25ms+28ms, total 125ms
E/Inbox[test#example.com]( 477): Uncaught exception in EasSyncServicejava.lang.ArrayIndexOutOfBoundsException: length=32; index=32
E/Inbox[test#example.com]( 477): Sync ended due to an exception.
D/dalvikvm( 477): GC_CONCURRENT freed 376K, 6% free 8420K/8903K, paused 5ms+18ms, total 66ms
I don't think this is a problem with your networking setup. It looks like you have an error in your Sync code, that is causing the process to stop:
E/Inboxtest#example.com: Uncaught exception in EasSyncServicejava.lang.ArrayIndexOutOfBoundsException: length=32; index=32
E/Inboxtest#example.com: Sync ended due to an exception.
>
Wrap this code in a try/catch block to understand what is happening better.

how do I not show Dalvik debug messages in Android log

I see a lot of this:
06-19 17:29:11.911: DEBUG/dalvikvm(10028): GC_FOR_MALLOC freed 729K, 54% free 3490K/7431K, external 0K/512K, paused 39ms
06-19 17:29:11.941: DEBUG/dalvikvm(10028): GC_FOR_MALLOC freed <1K, 49% free 3855K/7431K, external 0K/512K, paused 29ms
repeatedly in the log. Is there a way to not show the Dalvik debug messages?
Simply set a logcat filter. You can do this graphically in Eclipse as well.

Categories

Resources