Xcode 提供了大量的未定义符号错误: Firebase_App 错误。

huangapple go评论96阅读模式
英文:

Xcode gives plenty of Undefined Symbol: Firebase_App error

问题

我将翻译您提供的内容,但不包括代码部分。以下是翻译好的部分:

我将我的Unity项目构建到Xcode,尝试在iOS设备上安装它。它给出了以下错误:

  • 未定义的符号:_Firebase_App_CSharp_FirebaseApp_GetApps
  • 未定义的符号:_Firebase_App_CSharp_FirebaseApp_RegisterLibrariesInternal
  • 未定义的符号:_Firebase_Auth_CSharp_AuthResult_AdditionalUserInfoInternal_get
  • 未定义的符号:_Firebase_Auth_CSharp_AuthResult_CredentialInternal_get
  • 未定义的符号:_Firebase_Auth_CSharp_AuthResult_UserInternal_get
  • 未定义的符号:_Firebase_Auth_CSharp_AuthResult_UserInternal_set
  • 未定义的符号:_Firebase_Auth_CSharp_FirebaseAuth_CreateUserWithEmailAndPasswordInternalAsync
  • 未定义的符号:_Firebase_Auth_CSharp_FirebaseAuth_CreateUserWithEmailAndPasswordInternalAsync_DEPRECATED
  • 未定义的符号:_Firebase_Auth_CSharp_FirebaseAuth_SignInAndRetrieveDataWithCredentialInternalAsync

总共有69个类似的错误。我尝试添加了GameKit.framework,但仍然出现相同的错误。

XCode版本:14.3.1 (14E300c)
Firebase pod版本:10.12.0,我还尝试了10.11.0和10.10.0
最低iOS版本:12.0
Unity版本:2021.3.16
Firebase Unity SDK版本:11.1.0

我的Podfile如下:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '12.0'

target 'UnityFramework' do
  pod 'FBSDKCoreKit', '~> 16.0'
  pod 'FBSDKCoreKit_Basics', '~> 16.0'
  pod 'FBSDKGamingServicesKit', '~> 16.0'
  pod 'FBSDKLoginKit', '~> 16.0'
  pod 'FBSDKShareKit', '~> 16.0'
  pod 'FirebaseAuth', '10.11.0'
  pod 'FirebaseCore', '10.11.0'
  pod 'FirebaseDatabase', '10.11.0'
  pod 'FirebaseStorage', '10.11.0'
end

target 'Unity-iPhone' do
end

use_frameworks!

有谁能协助我解决这个问题吗?

英文:

I Build my Unity project to Xcode, trying to install it on ios device. It gives errors like as follow

> Undefined symbol: _Firebase_App_CSharp_FirebaseApp_GetApps
> 
> Undefined symbol:
> _Firebase_App_CSharp_FirebaseApp_RegisterLibrariesInternal
> 
> Undefined symbol:
> _Firebase_Auth_CSharp_AuthResult_AdditionalUserInfoInternal_get
> 
> Undefined symbol:
> _Firebase_Auth_CSharp_AuthResult_CredentialInternal_get
> 
> Undefined symbol: _Firebase_Auth_CSharp_AuthResult_UserInternal_get
> 
> Undefined symbol: _Firebase_Auth_CSharp_AuthResult_UserInternal_set
> 
> Undefined symbol:
> _Firebase_Auth_CSharp_FirebaseAuth_CreateUserWithEmailAndPasswordInternalAsync
> 
> Undefined symbol:
> _Firebase_Auth_CSharp_FirebaseAuth_CreateUserWithEmailAndPasswordInternalAsync_DEPRECATED
> 
> Undefined symbol:
> _Firebase_Auth_CSharp_FirebaseAuth_SignInAndRetrieveDataWithCredentialInternalAsync

totally gives 69 error like this.

I tried to add GameKit.framework, but still continue.

XCode version is: 14.3.1 (14E300c)
Firebase pod versions: 10.12.0, also I tried with 10.11.0 and 10.10.0
minimum ios version is:12.0
Unity Version is: 2021.3.16.
Firebase Unity SDK is: 11.1.0

and my podfile:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '12.0'

target 'UnityFramework' do
  pod 'FBSDKCoreKit', '~> 16.0'
  pod 'FBSDKCoreKit_Basics', '~> 16.0'
  pod 'FBSDKGamingServicesKit', '~> 16.0'
  pod 'FBSDKLoginKit', '~> 16.0'
  pod 'FBSDKShareKit', '~> 16.0'
  pod 'FirebaseAuth', '10.11.0'
  pod 'FirebaseCore', '10.11.0'
  pod 'FirebaseDatabase', '10.11.0'
  pod 'FirebaseStorage', '10.11.0'
end
target 'Unity-iPhone' do
end
use_frameworks!

Can anyone assist me on this.

答案1

得分: 0

我也在几天前遇到了同样的错误。不管你的 pod 文件如何,你的项目中都会有一些 DLL 文件,它们试图调用旧的方法。所以要么更新你的 DLL 文件,要么删除不需要的 DLL 文件。

英文:

I also face same error few days ago. Irrespective of your pod file there will be some dll present in your project that trying to call old methods. So either you update your dll files or delete unwanted dll files.

答案2

得分: 0

我解决了这个问题。

将Unity中的Firebase插件升级到11.3.0。

英文:

I solved this.

upgraded firebase plugin in Unity to 11.3.0

huangapple
  • 本文由 发表于 2023年7月27日 22:27:41
  • 转载请务必保留本文链接:https://go.coder-hub.com/76780733.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定