Failure [INSTALL_FAILED_DEXOPT]

edited March 2017 in Android Mode

Hi, i'm not english so i'm sorry if it doesn't not easy to read my text. If you are french, speack french please, it will be better for me (or us). I'm a programmer with a medium level. I use Processing and his Android Mode. My program is a long, simple for me, it's just for write text in english, french and spanish. When i will finish my party, i will give my code at my friends, who will put in his application. I hope you understand me. So, i want to work at home but i can't because i have again a problem. I'm on Linux, because Processing doesn't working in Windows (for me).

Here is my problem : (just the error)

debug: Failure [INSTALL_FAILED_DEXOPT] Shutting down any existing adb server...

Answers

  • Nattyx is your problem solved?

    Guys, I am also facing the same problem kindly help us out!!!!

  • @nattyx===

    in a lot of cases this message means that you have some problem with your SDK && your build tools. have you already build sucessfully an app with P5??? have you updated your SDK??? what version of android are you using when compiling?

  • I have the same problem with a Samsung galaxy Core prime phone running with a Dell XPS laptop. It has been working fine for six months up to a day ago with some quite complex programs and then started failing to connect with all my known good programs as well as with the simplest of examples given by Processing.

    I have completely cleared and reinstalled the Samsung ADB USB driver interface, which the computer reports as working perfectly and indeed it does on all my other apps. I have tried MTB and PTP modes for the USB.

    I've cleared and reinstalled all the Processing files and reinstalled Android and the SDK files upgrading to API7.1.1(25) as suggested by an earlier debug message. I've tested with the simplest of line drawing programs. The debug message currently reads:

    -post-build: debug: Failure [INSTALL_FAILED_DEXOPT] Shutting down any existing adb server...

    The test program is void setup() { size(640, 360); background(102); }

    void draw() { stroke(255); if (mousePressed == true) { line(mouseX, mouseY, pmouseX, pmouseY); } }

    In summary the Android USB connection works well with all my other Apps, used to work well with Processing and has suddenly failed and completely clearing and reinstalling the USB ADB driver, Processing3.3, Android, the Processing Sketch folder does not clear the problem.

    I'd be keen to hear what other people have done to try and fix this problem.

    Cheers, Peter

  • @PeterO===

    normally you must have more details about the error in the log; is it the case??? can you post the complete error code?

  • The code for drawing a line gives no console log or errors when compiled in Java but there is a large console log with warnings copied below when compiled in Android. I used the automatic install for the Android SDK and then the ADM manager recommendation to upgrade to API7.1.1(25) as suggested by an earlier debug message.

    The console log is very long for this forum as it is several pages so I've just included the red section warnings. They are for imports that I didn't include in the very simple code but assumed had something to do with redundant facilities in the SDK. Should I include the whole console log?

    Warnings from Console Log

    Code void setup() { size(640, 360); background(102); }

    void draw() { stroke(255); line(30, 20, 85, 75); }

    Error Log extract


    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 4) import processing.data.*; ^^^^^^^^^^^^^^^

    The import processing.data is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 5) import processing.event.*; ^^^^^^^^^^^^^^^^

    The import processing.event is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 6) import processing.opengl.*; ^^^^^^^^^^^^^^^^^

    The import processing.opengl is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 8) import java.util.HashMap; ^^^^^^^^^^^^^^^^^

    The import java.util.HashMap is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 9) import java.util.ArrayList; ^^^^^^^^^^^^^^^^^^^

    The import java.util.ArrayList is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 10) import java.io.File; ^^^^^^^^^^^^

    The import java.io.File is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 11) import java.io.BufferedReader; ^^^^^^^^^^^^^^^^^^^^^^

    The import java.io.BufferedReader is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 12) import java.io.PrintWriter; ^^^^^^^^^^^^^^^^^^^

    The import java.io.PrintWriter is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 13) import java.io.InputStream; ^^^^^^^^^^^^^^^^^^^

    The import java.io.InputStream is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 14) import java.io.OutputStream; ^^^^^^^^^^^^^^^^^^^^

    The import java.io.OutputStream is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\DrawLine.java (at line 15) import java.io.IOException; ^^^^^^^^^^^^^^^^^^^

    The import java.io.IOException is never used


    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\MainActivity.java (at line 11) import android.support.v4.content.ContextCompat; ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

    The import android.support.v4.content.ContextCompat is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\MainActivity.java (at line 15) import android.Manifest; ^^^^^^^^^^^^^^^^

    The import android.Manifest is never used

    1. WARNING in C:\Users\PeterO\AppData\Local\Temp\android4668128371280516557sketch\src\processing\test\drawline\MainActivity.java (at line 49) int check; ^^^^^

    The value of the local variable check is not used

    14 problems (14 warnings)

    Then at the end

    debug: Failure [INSTALL_FAILED_DEXOPT] Shutting down any existing adb server...

  • @PeterO===

    thses are "normal" warnings about unused imports automatically made by p5; and they are throwned before installing; but when the app crashes have you any other error message? - if you have as or eclipse installed, launch them(even without any code) have a look to the logcat,which is more efficient than p5 console.

  • Hi, Akenaton, what do you mean by "p5" ? I tried with my professor to fix my problem, he doesn't solved my problem. We past 2 houres on this problem. I tried to compil my program with processing on 3 computers, only 1 work. But the computer who processing work is in college ("lycée" in french) so i can't work at home. I also tried compil on 3/4 different phone with the computers who processing don't work. Same problem on the phones. And, the last try i did don't work too : it was to change the cable (usb to phone) for each computers, each phones. And, of course, my SDK and build tools are download. i tried a lot of time to uninstall and install SDK and build tools. I'm despair. Processing have a lot of problems, too much for me. Bye, good day.

  • @Nattyx=== P5= processing... i see that you have used the automatic install for SDK try to download it from the android site, put it where you want and use it instead of the previous one from p5...

  • @akenaton Greatly appreciate your comments and suggestions.

    You suggested using AS and Eclipse (for android) and I've never used either as Processing was my first introduction to Android so I'm going to download AS, learn how to use it and try your suggestion, but it may take two or three weeks of spare time as I have to go on a field trip next week a long way from internet conectivity.

    I also tried an older version of Processing (3.2.3) on an HP Mini netbook (Atom processor) running 32 bit Windows 7. It worked fine with the Samsung Galaxy Core Prime mobile phone. But the Windows 7 version on the Dell XPS computer (Intel Core i5) continues to fail.

    Thanks and hope this is also useful for Nattyx.

    Peter

  • edited April 2017

    @akenaton, @Nattyx

    I tried AS as you suggested and it compiled a simple "Hello World" and ran it on my phone. Kaspersky virus checker did also report an heur.trojan.AndroidOS virus message associatedd with running the AS software into the phone others have reported this in the last few days and it looks as if its been fixed now and may not have been a virus.

    The source of the original problem was that I had used the sdk default packages and the default additional packages. When I tried additions from an alternative set that had worked on my earlier version of the project the problem was resolved. In case its helpful I've listed the packages I used noting that I don't use simulators and therefore haven't included the very large system image files.

    Android SDK Tools /
    Android SDK Platform Tools /
    Android SDK Build Tools /
    (7.1.1) SDK Platform /
    (7.1.1) Sources for Android SDK /
    (6.0) SDK Platform /
    (5.1.1) SDK Platform /
    (5.1.1) Google APIs /
    (5.1.1) Sources for Android SDK /
    (Extras) Google Play Services /
    (Extras) Google USB Driver /
    

    Many thanks for the discussion

  • @PeterO=== ok, that was what i thought; put answered for others because that is a ecurrent problem.

  • Hi, Thanks you for all your comments and suggestions but I can't use AS, i must use Processing. I'm not a programmer who work at home, i'm just a student. You don't have any idea for fix my problem ? (I tried to change the processing version, useless.) Bye, good day !

Sign In or Register to comment.