错误:包名称为"com.facebook.android"的多个库



朋友,我在我的项目中使用Facebook SDK,使用Unity2017.1.1,在构建时发生了此错误。请帮助

CommandInvokationFailure:渐变生成失败。C:/Program Files\Java/jdk1.8.0_261\bin\Java.exe-classpath"C: \Program Files\Unity 2017.1.1\Unity\Editor\Data\PlaybackEngines\AndroidPlayer\Tools\gradle\lib\gradle-launcher-2.14.jar"org.gradlelauncher.GradleMain";assemblyRelease";

stderr

失败:生成失败,出现异常

  • 出了什么问题:任务":processReleaseResources"的执行失败

错误:多个包名为"com.facebook.android"的库

  • 尝试:使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug选项运行以获得更多日志输出。]标准输出[增量java编译是一个正在酝酿的特性。:预构建更新日期:预发布构建至今:checkReleaseManifest:预调试构建至今:unity android资源:预构建更新日期:unity android资源:preReleaseBuild更新日期:unity android资源:compileReleaseNdk更新日期:unity android资源:compileLint:unity安卓资源:copyReleaseLint更新日期:unity android资源:mergeReleaseProguard文件更新:unity android资源:packageReleaseRenderscript更新日期:unity android资源:checkReleaseManifest:unity android资源:prepareReleaseDependencies:unity android资源:compileReleaseRenderscript:unity android资源:generateReleaseResValues更新:unity android资源:generateReleaseResources:unity android资源:packageReleaseResources:unity android资源:compileReleaseAidl:unity android资源:generateReleaseBuildConfig:unity android资源:mergeReleaseShaders:unity android资源:compileReleaseShaders:unity android资源:generateReleaseAssets:unity android资源:mergeReleaseAssets:unity android资源:processReleaseManifest:unity android资源:processReleaseResources:unity android资源:generateReleaseSources:unity android资源:增量发布JavaCompilationSafeguard:unity android资源:compileReleaseJavaWithJavac:unity android资源:processReleaseJavaRes更新日期:unity android资源:transformResourcesWithMergeJavaResForRelease:unity android资源:transformClassesAndResourcesWithSyncLibJarsForRelease:unity android资源:mergeReleaseJniLibFolders:unity android资源:transformNative_libsWithMergeJniLibsForRelease:unity android资源:transformNative_libsWithSyncJniLibsForRelease:unity android资源:bundleRelease:prepareAndroidxAppcompatAppcompat100库最新版本:prepareAndroidxArchCoreCoreRuntime200库最新版本:prepareAndroidxAsynclayoutineflaterAsynclayout flater100库更新日期:prepareAndroidxBrowserBrowser100库最新版本:prepareAndroidxCardviewCardview100库最新版本:prepareAndroidxCordinatorlayout Coordinatorlayout 100库更新:prepareAndroidxCoreCore100库最新版本:prepareAndroidxCursoradapterCursoradapter100库更新:prepareAndroid自定义视图自定义视图100库最新版本:prepareAndroidxDocumentfileDocumentfile100库最新版本:prepareAndroidx抽屉布局抽屉布局100库最新:prepareAndroidxFragmentFragment100库最新版本:prepareAndroidxInterpolatorInterpolator100库最新版本:prepareAndroidxLegacyLegacySupportCoreUi100库最新版本:prepareAndroidxLegacyLegacySupportCoreUtils100库最新版本:prepareAndroidxLegacyLegacySupportV4100库最新版本:prepareAndroidx生命周期生命周期生命数据200库更新:prepareAndroidx生命周期生命周期生命数据核心200库更新:prepareAndroidx生命周期生命周期运行时间200库更新:prepareAndroidx生命周期生命周期查看模型200库更新:prepareAndroidxLoaderLoader100库最新版本:prepareAndroidxLocalbroadcastmanagerLocalbroadcast manager100库更新:prepareAndroidxMedia100库最新版本:prepareAndroidPrint100库最新版本:prepareAndroidx滑动面板布局滑动面板布局100库更新:prepareAndroidxSwiperefreshlayoutSwiperefershlayout100库更新:prepareAndroidxVectorDrawableVectorDrawable 100库更新:prepareAndroidxVectorDrawableVectorDrawable动画100库更新:prepareAndroidxVersionedparcelableVersionedparCelable100库更新:prepareAndroidxViewpagerViewpager100库最新版本:prepareAnimationVectorDrawable2340库最新版本:prepareCardviewV72340库最新版本:prepareComAndroidSupportAnimatedVectorDrawable2600阿尔法库更新:prepareComAndroidSupportAppcompatV72600Alpha1库最新版本:prepareComAndroidSupportSupportCompat2600Alpha1Library最新版本:prepareComAndroidSupportSupportCoreUi2600阿尔法库最新版本:prepareCoredSupportSupportCoreUtils2600Alpha1Library最新版本:prepareComAndroidSupportSupportFragment2600Alpha1库最新版本:prepareComAndroid支持MediaCompat2600Alpha1Library最新版本:prepareComAndroidSupportV42600Alpha1库最新版本:prepareComAndroidSupportSupportVectorDrawable2600Alpha1库最新版本:prepareCommonLibrary最新版本:prepareCustomabs2340库最新版本:prepareFacebookAndroidSdk4170库最新版本:prepareFacebookAndroidSdk460库最新版本:prepareFacebookAndroidWrapper790Library最新版本:prepareFacebookAndroidWrapperRelaseLibrary最新版本:准备GoogleAIDLLLibrary最新版本:准备GooglePlayLibrary最新版本:prepareGradleOutUnityAndroidResourcesUnspecifiedLibrary:preparePlayServicesBase1102图书馆最新版本:prepareSupportCompat2520库最新版本:prepareSupportCoreUi2520库最新版本:prepareSupportCoreUtils2520库最新版本:prepareSupportFragment2520库最新版本:prepareSupportMediaCompat2520库最新版本:prepareSupportV42340库最新版本:prepareSupportV42520库最新版本:prepareSupportVectorDrawable2340库最新版本:prepareReleaseDependencies:compileReleaseAidl最新版本:compileReleaseRenderscript最新版本:generateReleaseBuildConfig最新版本:mergeReleaseShaders最新版本:compileReleaseShaders最新版本:generateReleaseAssets最新版本:mergeReleaseAssets:generateRelaseResValues最新:generateRelease资源更新:mergeReleaseResources:processReleaseManifest:processReleaseResources失败

BUILD FAILED

总时间:37.752秒]退出代码:1UnityEditor.Android.Command.Run(System.Diagnostics.ProcessStartInfo psi,UnityEditor.Android.WaitingForProcessToExit WaitingForProcessToExit,System.String errorMsg)UnityEditor.Android.GradleWrapper.RunJava(System.String参数,System.String工作目录,UnityEditor.Android.Progress进度)重新显示为GradleInvokationException:Gradle生成失败UnityEditor.Android.GradleWrapper.RunJava(System.String参数,System.String工作目录,UnityEditor.Android.Progress进度)UnityEditor.Android.GradleWrapper.Run(System.String工作目录,System.String任务,UnityEditor.Android.Progress进度)UnityEditor.Android.PostProcessor.Tasks.BuildGradleProject.Execute(UnityEditor.Android_PostProcessor.PostProcessorContext上下文)UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks(UnityEditor.Android.PostProcessor.Post ProcessorContext上下文)UnityEditor.HostView:OnGUI()

通过从Lib文件夹中删除所有与facebook相关的文件解决了此错误。不知道这是否是解决方案,但那个错误已经消失了。

最新更新