2
私はこの質問に名前を付けるために何をすべきか分かりませんでした。Androidスタジオ2.0グラデルバグ
私は自分のPCと私のMacの2台のマシンで作業します。現在、私はすべての新機能を得るために自分のPC上でAndroid Studio 2.0にアップグレードしました。私は助けが必要です。
だから私はアプリを実行しようとすると、グラデルビルドが失敗するということです。これは、このメッセージで失敗します。
Executing tasks: [:app:clean, :app:generateDebugSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies, :app:generateDebugAndroidTestSources, :app:assembleDebug]
Configuration on demand is an incubating feature.
Incremental java compilation is an incubating feature.
:app:clean
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAnimatedVectorDrawable2320Library
:app:prepareComAndroidSupportAppcompatV72320Library
:app:prepareComAndroidSupportDesign2320Library
:app:prepareComAndroidSupportRecyclerviewV72320Library
:app:prepareComAndroidSupportSupportV42320Library
:app:prepareComAndroidSupportSupportVectorDrawable2320Library
:app:prepareDebugDependencies
:app:compileDebugAidl
:app:compileDebugRenderscript
:app:generateDebugBuildConfig
:app:generateDebugAssets UP-TO-DATE
:app:mergeDebugAssets
:app:generateDebugResValues UP-TO-DATE
:app:generateDebugResources
:app:mergeDebugResources
:app:processDebugManifest
:app:processDebugResources
:app:generateDebugSources
:app:mockableAndroidJar UP-TO-DATE
:app:preDebugUnitTestBuild UP-TO-DATE
:app:prepareDebugUnitTestDependencies
:app:preDebugAndroidTestBuild UP-TO-DATE
:app:prepareDebugAndroidTestDependencies
:app:compileDebugAndroidTestAidl
:app:processDebugAndroidTestManifest
:app:compileDebugAndroidTestRenderscript
:app:generateDebugAndroidTestBuildConfig
:app:generateDebugAndroidTestAssets UP-TO-DATE
:app:mergeDebugAndroidTestAssets
:app:generateDebugAndroidTestResValues UP-TO-DATE
:app:generateDebugAndroidTestResources
:app:mergeDebugAndroidTestResources
:app:processDebugAndroidTestResources
:app:generateDebugAndroidTestSources
:app:compileDebugJavaWithJavac
:app:compileDebugNdk UP-TO-DATE
:app:compileDebugSources
:app:buildInfoDebugLoader
:app:transformClassesWithExtractJarsForDebug
:app:transformClassesWithInstantRunVerifierForDebug
:app:transformClassesWithJavaResourcesVerifierForDebug
:app:mergeDebugJniLibFolders
:app:transformNative_libsWithMergeJniLibsForDebug
:app:processDebugJavaRes UP-TO-DATE
:app:transformResourcesWithMergeJavaResForDebug FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:transformResourcesWithMergeJavaResForDebug'.
> com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK META-INF/BCKEY.SF
File1: C:\Users\Andy\.gradle\caches\modules-2\files-2.1\org.bouncycastle\bcpkix-jdk15on\1.51\6c8c1f61bf27a09f9b1a8abc201523669bba9597\bcpkix-jdk15on-1.51.jar
File2: C:\Users\Andy\.gradle\caches\modules-2\files-2.1\org.bouncycastle\bcprov-jdk15on\1.51\9ab8afcc2842d5ef06eb775a0a2b12783b99aa80\bcprov-jdk15on-1.51.jar
- 試してみてください。--stacktraceオプション付き 実行して、スタックトレースを取得します。より多くのログ出力を得るには、--infoまたは--debugオプションを指定して実行します。
BUILDは
合計時間FAILED:15.114秒
はここで今、奇妙なことは、私がまったく同じソースコードを実行した場合というのが私の依存関係
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:23.2.0'
compile 'com.google.code.gson:gson:2.5'
compile 'com.hierynomus:sshj:0.15.0'
compile 'joda-time:joda-time:2.9.1'
compile 'de.greenrobot:eventbus:2.4.0'
compile 'com.android.support:support-v4:23.2.0'
compile 'com.android.support:design:23.2.0'
}
のリストです私のマックは大丈夫です。では何が起こっているのですか?これはv2.0のバグですか?
これ以上の情報が必要な場合はお知らせください。 sshjも弾む城を望むと、そのためのAndroidの一つに固まっと競合した
おかげ
アンディ
これらの行だけでなく、Gradleコンソールの出力全体を投稿してください。 – CommonsWare
@CommonsWare done – Andy
OK、2つの別々のBouncy Castle JARからファイルを複製しています。彼らが最近リパッケージされていない限り、Bouncy CastleはAndroidアプリにはお勧めできません。なぜなら、AndroidにはBouncy Castleの切り詰め版があり、紛争に巻き込まれるからです。以前は[Spongy Castle](https://rtyley.github.io/spongycastle/)を使用しなければならないということでした。私はそれを副作用としてこの問題を解決するかもしれないので、まずそれに焦点を当てます。それ以外の場合は、このファイルの1つのコピーで終了するだけの除外ルールを見つけます。 – CommonsWare