Android工具内部出错,请检查控制台 - 处理2.0,Android模式

时间:2013-06-16 02:53:51

标签: android sdk processing

问题摘要: 我无法在Android设备上运行程序,也无法在模拟器中运行程序。我安装了Android SDK 2.33(API10)和所有组件,也包括4.1和更高版本。我为HTC EVO V 4G(维珍移动)安装了新的USB驱动程序,但仍然没有。我检查了SDK的路径,处理正确找到它。我花了一整天的时间在线研究它,重新安装SDK,安装Processing 2.0 64位(因为我的SDK是64位)等等。

我正在尝试运行任何程序,甚至模板和空白列表。它总是给我同样的错误,无论我是在模拟器上运行还是通过我的Android设备运行它。 控制台告诉我:Android工具内部出错,请检查控制台

我的错误和编辑消息

-set-mode-check:

-set-debug-files:

-check-env:
Android SDK Tools Revision 22.0.1
Installed at F:\ANDROID SDK\sdk

-setup:
     [echo] Project Name: SonicPainterAndroid
Project Type: Application

-set-debug-mode:

-debug-obfuscation-check:

-pre-build:

-build-setup:
Using latest Build Tools: 17.0.0
     [echo] Resolving Build Target for SonicPainterAndroid...
Project Target:   Android 2.3.3
API level:        10
     [echo] ----------
     [echo] Creating output directories if needed...
    [mkdir] Created dir: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin
    [mkdir] Created dir: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\res
    [mkdir] Created dir: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\gen
    [mkdir] Created dir: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\classes
    [mkdir] Created dir: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\dexedLibs
     [echo] ----------
     [echo] Resolving Dependencies for SonicPainterAndroid...
Library dependencies:
No Libraries

------------------
API<=15: Adding annotations.jar to the classpath.
     [echo] ----------
     [echo] Building Libraries with 'debug'...
   [subant] No sub-builds to iterate on

-code-gen:
Merging AndroidManifest files into one.
Manifest merger disabled. Using project manifest only.
     [echo] Handling aidl files...
No AIDL files to compile.
     [echo] ----------
     [echo] Handling RenderScript files...
No RenderScript files to compile.
     [echo] ----------
     [echo] Handling Resources...
Generating resource IDs...
     [echo] ----------
     [echo] Handling BuildConfig class...
Generating BuildConfig class.

-pre-compile:

-compile:
    [javac] Since compiler setting isn't classic or modern, ignoring fork setting.
    [javac] Since compiler setting isn't classic or modern, ignoring fork setting.
    [javac] Since compiler setting isn't classic or modern, ignoring fork setting.
    [javac] Compiling 3 source files to C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\classes
    [javac] Since compiler setting isn't classic or modern, ignoring fork setting.
    [javac] Note: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\src\processing\test\sonicpainterandroid\SonicPainterAndroid.java uses unchecked or unsafe operations.
    [javac] Note: Recompile with -Xlint:unchecked for details.

-post-compile:

-obfuscate:

-dex:
input: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\classes
input: F:\ANDROID SDK\sdk\tools\support\annotations.jar
input: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\libs\processing-core.jar
Pre-Dexing F:\ANDROID SDK\sdk\tools\support\annotations.jar -> annotations-6fd7360592e852b6775ac413fb7ed0ba.jar
Pre-Dexing C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\libs\processing-core.jar -> processing-core-777dbf75952a9afa0c94c831b5d89f0d.jar
Converting compiled files and external libraries into C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\classes.dex...
       [dx] Merged dex A (18 defs/19.5KiB) with dex B (2 defs/1.1KiB). Result is 20 defs/23.8KiB. Took 0.1s
       [dx] Merged dex A (20 defs/23.8KiB) with dex B (203 defs/686.6KiB). Result is 223 defs/838.1KiB. Took 0.2s

-crunch:
   [crunch] Crunching PNG Files in source dir: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\res
   [crunch] To destination dir: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\res
   [crunch] Processing image to cache: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\res\drawable-hdpi\icon.png => C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\res\drawable-hdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\res\drawable-hdpi\icon.png: 47% size of source)
   [crunch] Processing image to cache: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\res\drawable-ldpi\icon.png => C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\res\drawable-ldpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\res\drawable-ldpi\icon.png: 0% size of source)
   [crunch] Processing image to cache: C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\res\drawable\icon.png => C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\res\drawable\icon.png
   [crunch]   (processed image to cache entry C:\Users\SEBAST~1\AppData\Local\Temp\android1631735927318765460sketch\bin\res\drawable\icon.png: 0% size of source)
   [crunch] Crunched 3 PNG files to update cache

-package-resources:
Creating full resource package...
     [aapt] Warning: AndroidManifest.xml already defines debuggable (in http://schemas.android.com/apk/res/android); using existing value in manifest.

-package:
Current build type is different than previous build: forced apkbuilder run.
Creating SonicPainterAndroid-debug-unaligned.apk and signing it with a debug key...

BUILD FAILED
F:\ANDROID SDK\sdk\tools\ant\build.xml:955: The following error occurred while executing this line:
F:\ANDROID SDK\sdk\tools\ant\build.xml:966: The following error occurred while executing this line:
F:\ANDROID SDK\sdk\tools\ant\build.xml:310: com.android.sdklib.build.ApkCreationException: java.io.EOFException
    at com.android.sdklib.build.ApkBuilder.getDebugKey(ApkBuilder.java:308)
    at com.android.sdklib.build.ApkBuilder.<init>(ApkBuilder.java:392)
    at com.android.ant.ApkBuilderTask.execute(ApkBuilderTask.java:334)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
    at sun.reflect.GeneratedMethodAccessor47.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    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.GeneratedMethodAccessor47.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    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.GeneratedMethodAccessor47.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    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.GeneratedMethodAccessor47.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    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.GeneratedMethodAccessor47.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    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.GeneratedMethodAccessor47.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    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.GeneratedMethodAccessor47.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    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.EOFException
    at java.io.DataInputStream.readFully(DataInputStream.java:180)
    at java.io.DataInputStream.readUTF(DataInputStream.java:592)
    at java.io.DataInputStream.readUTF(DataInputStream.java:547)
    at sun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:685)
    at sun.security.provider.JavaKeyStore$JKS.engineLoad(JavaKeyStore.java:38)
    at java.security.KeyStore.load(KeyStore.java:1185)
    at com.android.sdklib.internal.build.DebugKeyProvider.loadKeyEntry(DebugKeyProvider.java:174)
    at com.android.sdklib.internal.build.DebugKeyProvider.<init>(DebugKeyProvider.java:107)
    at com.android.sdklib.build.ApkBuilder.getDebugKey(ApkBuilder.java:272)
    ... 60 more

Total time: 18 seconds

如何让Processing运行android程序?

1 个答案:

答案 0 :(得分:6)

我解决了!感谢abbas.aniefa的帖子位于here

所有必须做的就是删除位于

的调试密钥库文件
C:\Users\<UserName>\.android\debug.keystore

其中是计算机用户的名称

希望其他人会发现它和我一样有用。