Android mode isn't working !!!

edited October 2014 in Android Mode

Hello everybody, I have downloaded processing 2.2.1 and it has android mode installed in it but when I try to run my app on a real device it says :

BUILD FAILED C:\Android 1\adt-bundle-windows-x86-20131030\sdk\tools\ant\build.xml:483: The SDK Build Tools revision (19.0.0) is too low for project 'sketch_141006b'. Minimum required is 19.1.0

I have done a lot of research on the net but none of the suggested solutions was successful so what should I do now, I really need this.

Thanks in advance :)

Comments

  • update your sdk ???? (now i think it could be 23.0)

  • Hi akenaton and thanks for your answer, I updated my sdk to the latest version and now when I run my sketch on a device it says :

    BUILD FAILED C:\Android 1\adt-bundle-windows-x86-20131030\sdk\tools\ant\build.xml:720: The following error occurred while executing this line: C:\Android 1\adt-bundle-windows-x86-20131030\sdk\tools\ant\build.xml:734: Error running javac.exe compiler

    Please help

  • edited October 2014

    I would guess you have the Java JRE installed which is for end-users to run java programs, not compile them. You need the Java JDK which contains the support libraries and javac.exe compiler. You can find the appropriate JDK here: http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

    You will need the Windows x86 32-bit JDK, jdk-8u20-windows-i586.exe to compile Processing code properly (well hopefully, it can be a mess to debug so be forewarned).

    If you do have the JDK installed, then I'd guess it's misconfigured. Here's another link to help you with that possibility: http://docs.oracle.com/javase/tutorial/essential/environment/paths.html

  • you are on windows. I didnt' know. i think that @Sirius is wright. Of course you must have some jdk compiler!!!

  • edited October 2014

    Hello again, thanks for your answer SiriusCG and now after doing all that I'm getting the following errors :

    BUILD FAILED C:\Android 1\adt-bundle-windows-x86-20131030\sdk\tools\ant\build.xml:962: The following error occurred while executing this line: C:\Android 1\adt-bundle-windows-x86-20131030\sdk\tools\ant\build.xml:973: The following error occurred while executing this line: C:\Android 1\adt-bundle-windows-x86-20131030\sdk\tools\ant\build.xml:312: com.android.sdklib.build.ApkCreationException: java.io.FileNotFoundException: C:\Users\USER\AppData\Local\Temp\android3477315967713921780sketch\bin\classes.dex does not exist at com.android.sdklib.build.ApkBuilder.init(ApkBuilder.java:469) at com.android.sdklib.build.ApkBuilder.(ApkBuilder.java:394) at com.android.ant.ApkBuilderTask.execute(ApkBuilderTask.java:334) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor17.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor17.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:398) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor17.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68) at com.android.ant.IfElseTask.execute(IfElseTask.java:124) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor17.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68) at com.android.ant.IfElseTask.execute(IfElseTask.java:124) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor17.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor17.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:398) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor17.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:390) at org.apache.tools.ant.Target.performTasks(Target.java:411) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399) at org.apache.tools.ant.Project.executeTarget(Project.java:1368) at processing.mode.android.AndroidBuild.antBuild(AndroidBuild.java:415) at processing.mode.android.AndroidBuild.build(AndroidBuild.java:73) at processing.mode.android.AndroidMode.handleRunDevice(AndroidMode.java:220) at processing.mode.android.AndroidEditor$14.run(AndroidEditor.java:310) Caused by: java.io.FileNotFoundException: C:\Users\USER\AppData\Local\Temp\android3477315967713921780sketch\bin\classes.dex does not exist at com.android.sdklib.build.ApkBuilder.checkInputFile(ApkBuilder.java:938) at com.android.sdklib.build.ApkBuilder.init(ApkBuilder.java:440) ... 60 more

    PS : when I downloaded and installed jdk (the last version) I didn't find javac.exe in the bin folder so made the reference to the PATH system variable from jdk1.7 instead of 1.8

  • edited October 2014

    At this juncture, I'll assume your install is simply screwed up. My suggestion: Uninstall both the ADT , Java and Processing. Clean up your PATH variable. Reboot your PC completely by powering off and on.

    Go to this page and find my post about halfway down on February 12th. http://forum.processing.org/two/discussion/2928/has-anybody-had-success-with-procesing-2-0-3-and-android-#Item_11 and follow the instructions. Make version adjustments as necessary for the newer versions of the programs.

    I had issues at first getting Processing to work with my pre-existent Java and ADT installs. Cleaning everything up and reloading it as I describe fixed most of the compilation errors regarding libraries and files not being found.

  • edited October 2014

    Sorry but what do you mean by "clean up your PATH variable" ? should I retrun it to the same value as it was before ? thanks

  • edited October 2014

    Yes, any changes you made to your PATH variable previously, you need to delete. Actually, if you find any other references to JAVA in your path, I'd remove them as well. By reinstalling the programs in the sequence I outline in my other post, it "should" modify the PATH appropriately.

  • edited October 2014

    Hi again SiriusCG, I did all what you said but I'm facing the same problem again, do you have any more suggestions, I'm at the point of giving up man :(

  • edited October 2014

    I'll have to do some rooting around ... I'll get back to you.

  • The classes.dex file is an intermediate file format before the program is archived into an .apk package for Android. The only thing I can think of currently is that your version of ant is somehow defective, as most of the error messages appear to be concerned with ant failing to find the needed files. Or, this could be a permissions problem in Windows.

    What version of Windows are you using currently?

  • Hi SiriusCG, thanks again for your answers, they were very helpful, I did some routing myself and after changing alot of things I now have this new problem :

    BUILD FAILED C:\Program Files\Android\android-studio\sdk\tools\ant\build.xml:720: The following error occurred while executing this line: C:\Program Files\Android\android-studio\sdk\tools\ant\build.xml:734: Error running javac.exe compiler

    Total time: 7 seconds Thanks in advance.

Sign In or Register to comment.