我试图实现谷歌登录为Android和我按照说明通过
https://developers.google.com/identity/sign-in/android/start-integrating
但在构建应用程序时,我收到了以下错误。
信息: Gradle任务[: app: GenerateDebugSsource,: app: GenerateDebugAndroid测试源,: app: assembleDebug]: app: preBuild Up-TO-DATE: app: preDebugBuild Up-TO-DATE: app: check DebugManiFestival: app: preRelaseBuild Up-TO-DATE: app: preareComAndreidSupportAppcompatV72301库Up-TO-DATE: app: preareComAndreidSupportDesign2301库Up-TO-DATE: app: predebugBuild ComGoogleAndreidGmsPlayServicesAds810库Up-TO-DATE: app: preareComGoogleAndroid idGmsPlayServicesAnalytics810Library Up-TO-DATE: app: preareComGoogleAndroid idGmsPlayServicesAppindexing810Library Up-TO-DATE: app: preareComGoogleAndroid idGmsPlayServicesAppindexing810库UUP-TO-DATE: app: compileDebugRendercript UP-TO-DATE: app: GenerateDebugBuildConfig UP-TO-DATE: app: GenerateDebugAsset UP-TO-DATE: app: GenerateDebugResValuesUP-TO-DATE: app: ProcateDebugGoogleServices没有找到匹配的客户端包名称'com.questo.rugved.questo': app: GenerateDebugResources: app: mergeDebugResources UP-TO-DATE: app:进程DebugManifestUP-TO-DATE: app:进程DebugResources UP-TO-DATE: app: GenerateDebugSsource UP-TO-DATE: app: preDebugAndreidTestBuild UP-TO-DATE: app:编译DebugAndreidTestAtendents: app:编译DebugAndreidTestAidl UP-TO-DATE: app:进程DebugAndreidTestManiFestivalUP-TO-DATE: app: compileDebugAndreidTestRendercript UP-TO-DATE: app: GenerateDebugAndreidTestBuildConfig UP-TO-DATE: app: GenerateDebugAndreidTestAsset UP-TO-DATE: app: GenerateDebugAndreidTestResValuesUP-TO-DATE: app: GenerateDebugAndreidTestResources UP-TO-DATE: app: GenerateDebugAndreidTestResources UP-TO-DATE: app: GenerateDebugAndreidTestResources UP-TO-DATE: app: GenerateDebugAndreidTestSsource UP-TO-DATE: app: compileDebugJavawith Javac UP-TO-DATE: app: compileDebugNdk UP-TO-DATE: app: compileDebugSsource UP-TO-DATE: app: transformClassesAndResourc.com.android.build.transform.api.转换异常:com.android.ide.common.process.进程异常:org.gradle.process.internal.执行异常:进程'命令'/usr/lib/jvm/java-7-oracle/bin/java"以非零退出值完成2信息:构建失败信息:总时间:1分钟39.994秒信息:1错误信息:0警告信息:请参见控制台中的完整输出
我的顶级毕业生是
buildscript { repositories { jcenter() } dependencies { classpath 'com.android.tools.build:gradle:1.3.0' classpath 'com.google.gms:google-services:1.4.0-beta3' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files } } allprojects { repositories { jcenter() } }
My app level gradle is
<pre>
apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'
android {
compileSdkVersion 23
buildToolsVersion '23.0.1'
defaultConfig {
applicationId "com.questo.rugved.questo"
minSdkVersion 15
targetSdkVersion 23
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:23.0.1'
compile 'com.android.support:design:23.+'
compile 'com.google.android.gms:play-services-identity:8.1.0'
compile 'com.google.android.gms:play-services-plus:8.1.0'
}
请帮忙。
添加
dexOptions {
incremental = true;
preDexLibraries = false
javaMaxHeapSize "4g" // 2g should be also OK
}
Android系统内置。格雷德尔为我工作。
出现此问题的原因是包含多个依赖项。您正在包含已在生成中指定的依赖项。格雷德尔档案。例如:
compile 'com.google.android.gms:play-services:9.0.2'
compile 'com.google.android.gms:play-services-identity:9.0.2'
上面的依赖性规范会产生这个问题,因为play services包括一切,包括play services identity,
推荐的选项是只包含您实际需要的依赖项。如果您需要播放服务位置
compile 'com.google.android.gms:play-services-location:9.0.2'
compile 'com.google.android.gms:play-services-maps:9.0.2'
没有包括所有与'com.google.Android游戏服务:9.0.2'。
在您的具体案例中,我怀疑谷歌顶级gradle文件服务和play服务身份之间存在冲突
一般来说,如果没有强大的
也许这个链接对你有帮助。链接
这帮助了我:
android {
...
defaultConfig {
...
multiDexEnabled true
}
}
当我要构建apk时,我收到此错误。 执行任务“app:transformClassesWithDexForDebug”失败。 这是错误的截图
我已经迁移到Android Studio 2.0预览版,不管我做什么,我都得到了: com.android.build.api.transform.transformException:com.android.ide.common.Process.processException:org.gradle.Process.internal.execexception:进程“command”C:\jdk
我的应用程序正在正确编译,在我添加谷歌地图活动之前。然后我得到这个错误 build.gradle 有人能帮我解决这个问题吗。tnx
我不想开始一个与这个问题相关的新问题,因为我知道已经有几个了,但我仍然没有找到解决方案,我卡住了。 我当前收到错误: 错误:任务执行失败:app:transformClassesWithDexForDebug。 “进程”异常: “目录 jdk1.7.0_79”以非零退出值 2 完成 这就是Gradle控制台的功能 意外的顶级异常:com.android.dex.DexException:多个dex
错误:任务': app: transformClassesSusDexForDebug'执行失败。 com.android.build.api.transform.TransformException: com.android.ide.common.process.processexception: java.util.concurrent.ExecutionException: com.andr
当我尝试使用构建我的项目时,我面临以下错误。也尝试增加堆大小,但没有运气。 我们将非常感谢您对为什么会发生这种情况的一些见解。