首页 > 解决方案 > Xamarin 在 iOS 中形成 Google Auth 导致 Azure DevOps 出现问题

问题描述

你好吗?

我有一个带有 facebook 身份验证的 Xamarin Forms 应用程序。为了将此应用程序发布到 appstoreconnect,我使用了 Azure DevOps 管道(使用 mac 主机执行该操作的默认模板)。

最近我也尝试使用 iOS 项目中的 Xamarin.Google.iOS.SignIn 库来提供谷歌身份验证。在调试期间,在模拟器中,一切运行良好。

当我尝试使用 Azure DevOps 在 appstoreconnect 中发布应用程序时,我在“构建 Xamarin.iOS 解决方案”步骤中获得了以下日志:

"/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj" (default target) (1) ->
(_CompileToNative target) -> 
  clang : error : linker command failed with exit code 1 (use -v to see invocation) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GTMOAuth2, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GTMOAuth2 (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GoogleSignIn, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GoogleSignIn (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseInstanceID, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseInstanceID (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseCore, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseCore (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseCoreDiagnostics, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseCoreDiagnostics (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseNanoPB, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseNanoPB (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GoogleToolboxForMac, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GoogleToolboxForMac (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/nanopb, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/nanopb (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GTMSessionFetcher, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GTMSessionFetcher (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/Protobuf, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/Protobuf (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GGLCore, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/GGLCore (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  error MT5209 : Native linking error : warning: ignoring file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseAnalytics, missing required architecture armv7s in file /Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/obj/iPhone/AppStore/mtouch-cache/FirebaseAnalytics (4 slices) [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIRAnalytics. The symbol '_OBJC_CLASS_$_FIRAnalytics' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIRAnalyticsConfiguration. The symbol '_OBJC_CLASS_$_FIRAnalyticsConfiguration' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIRApp. The symbol '_OBJC_CLASS_$_FIRApp' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIRConfiguration. The symbol '_OBJC_CLASS_$_FIRConfiguration' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIRInstanceID. The symbol '_OBJC_CLASS_$_FIRInstanceID' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIROptions. The symbol '_OBJC_CLASS_$_FIROptions' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GGLConfiguration. The symbol '_OBJC_CLASS_$_GGLConfiguration' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GGLContext. The symbol '_OBJC_CLASS_$_GGLContext' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GIDAuthentication. The symbol '_OBJC_CLASS_$_GIDAuthentication' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GIDGoogleUser. The symbol '_OBJC_CLASS_$_GIDGoogleUser' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GIDProfileData. The symbol '_OBJC_CLASS_$_GIDProfileData' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GIDSignIn. The symbol '_OBJC_CLASS_$_GIDSignIn' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GIDSignInButton. The symbol '_OBJC_CLASS_$_GIDSignInButton' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GMRConfiguration. The symbol '_OBJC_CLASS_$_GMRConfiguration' could not be found in any of the libraries or frameworks linked with your application. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5214: Native linking failed, undefined symbol: _kFIRInstanceIDScopeFirebaseMessaging. This symbol was referenced by the managed member Firebase.InstanceID.InstanceId.ScopeFirebaseMessaging. Please verify that all the necessary frameworks have been referenced and native libraries linked. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5214: Native linking failed, undefined symbol: _kFIRInstanceIDTokenRefreshNotification. This symbol was referenced by the managed member Firebase.InstanceID.InstanceId.TokenRefreshNotification. Please verify that all the necessary frameworks have been referenced and native libraries linked. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5214: Native linking failed, undefined symbol: _kGIDSignInErrorDomain. This symbol was referenced by the managed member Google.SignIn.SignIn.SignInErrorDomainKey. Please verify that all the necessary frameworks have been referenced and native libraries linked. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]
  MTOUCH : error MT5202: Native linking failed. Please review the build log. [/Users/vsts/agent/2.150.3/work/1/s/ApolarImoveis/ApolarImoveis.iOS/ApolarImoveis.iOS.csproj]

    145 Warning(s)
    31 Error(s)

这似乎发生在任何谷歌集成库中。那么,有人知道如何解决这个问题吗?

标签: xamarin.formsdeploymentxamarin.iosazure-devopsgoogle-authentication

解决方案


推荐阅读