我正在从“Learning Android”一书中构建一个项目。当我包含第三方 jtwitter-yamba.jar 文件时,我的项目在构建时失败:
我试图将其删除以实际验证其罪人。
有解决方法吗?我怀疑已经有一些 twitter API 隐藏在某个地方。
[2012-02-07 20:34:24 - Yamba] Dx
UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.IllegalArgumentException: already added: Llgpl/haustein/Base64Encoder;
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:123)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.dex.file.DexFile.add(DexFile.java:163)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.command.dexer.Main.processClass(Main.java:486)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.command.dexer.Main.processFileBytes(Main.java:455)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.command.dexer.Main.access$400(Main.java:67)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:394)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:245)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:131)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:109)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.command.dexer.Main.processOne(Main.java:418)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.command.dexer.Main.processAllFiles(Main.java:329)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.dx.command.dexer.Main.run(Main.java:206)
[2012-02-07 20:34:24 - Yamba] Dx at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2012-02-07 20:34:24 - Yamba] Dx at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[2012-02-07 20:34:24 - Yamba] Dx at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[2012-02-07 20:34:24 - Yamba] Dx at java.lang.reflect.Method.invoke(Method.java:597)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.ide.eclipse.adt.internal.build.DexWrapper.run(DexWrapper.java:179)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.ide.eclipse.adt.internal.build.BuildHelper.executeDx(BuildHelper.java:745)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.ide.eclipse.adt.internal.build.builders.PostCompilerBuilder.build(PostCompilerBuilder.java:634)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:728)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:199)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:321)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:396)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.resources.Project$1.run(Project.java:618)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2344)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.resources.Project.internalBuild(Project.java:597)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.resources.Project.build(Project.java:124)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.ide.eclipse.adt.internal.project.ProjectHelper.doFullIncrementalDebugBuild(ProjectHelper.java:961)
[2012-02-07 20:34:24 - Yamba] Dx at com.android.ide.eclipse.adt.internal.launch.LaunchConfigDelegate.launch(LaunchConfigDelegate.java:146)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:854)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:703)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:928)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1132)
[2012-02-07 20:34:24 - Yamba] Dx at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
[2012-02-07 20:34:24 - Yamba] Dx 1 error; aborting
[2012-02-07 20:34:24 - Yamba] Conversion to Dalvik format failed with error 1