【问题标题】:Framework not found Protobuf找不到框架 Protobuf
【发布时间】:2020-04-17 08:14:11
【问题描述】:

我面临一个问题,我需要为我的 iOS 应用程序使用 FirebaseRemoteConfig。我包含了以下 pod:

    pod 'Firebase/RemoteConfig'

现在当我在终端上运行命令时:

pod install 

它显示了错误:

Framework not found 'Protobuf'

这真的令人沮丧,因为在此之前项目运行良好。我尝试了一些堆栈溢出的建议,但无法解决问题。

# Uncomment this line to define a global platform for your project
platform :ios, '10.0'

# ignore all warnings from all pods
inhibit_all_warnings!

use_frameworks!
target 'S****k' do
pod 'AFNetworking', '~> 2.6'
pod 'TPKeyboardAvoiding', '~> 1.2'
pod 'SVProgressHUD', '~> 1.1'
pod 'Google/SignIn'
pod 'Mantle', '~> 2.0'
pod 'FBSDKCoreKit'#, '~> 4.8'
pod 'FBSDKLoginKit'#, '~> 4.8'
pod 'GooglePlaces', '~> 3.0.0'
#pod 'Firebase/Core'
pod 'GoogleTagManager'
pod 'GoogleIDFASupport'
pod 'Fabric'
pod 'Crashlytics'
pod 'AppsFlyerFramework'
pod 'KissXML'
pod 'GoogleMaps', '~> 3.0.0'
pod 'AutoScrollLabel'
pod "CleverTap-iOS-SDK"
pod 'IQKeyboardManager'
pod 'TrueSDK'
pod 'HyperSDK', '0.2.90'
pod 'ExpressCheckout'
#pod "AlignedCollectionViewFlowLayout"
pod 'UICollectionViewLeftAlignedLayout'
#pod 'TGLParallaxCarousel'
pod "JuspaySafeBrowser"
pod 'Firebase/RemoteConfig'

【问题讨论】:

  • protobuf 是嵌入在 FirebaseCore 中的东西。您是否将其包含在您的 pod 文件中?向我们展示您的 podfile 和更多错误截图。
  • 我已经编辑了帖子......这就是我的 pod 文件的样子。
  • 你为什么评论pod Firebase/Core?我认为这就是您缺少protobuf 框架的地方
  • 即使我取消注释它也不起作用
  • 清理构建文件夹怎么样,删除.xcworkspacePods/,运行pod update再试一次?还要检查您的 pod 项目(在项目导航器中)以查看 Protobuf 框架是否已正确安装(项目导航器 -> 目标)

标签: ios xcode firebase-remote-config


【解决方案1】:
  1. 请备份您的项目

  2. 让我们转到“您的项目”-> 构建设置

  3. find here 在这里找到“Other Linker Flags”并打开它

  4. 删除(点击“-”号)字符串“Protobuf”和“Protobuf”上方的字符串“framework”

  5. 清理构建文件夹(Command + SHIFT + K)并重建

  6. 就是这样

【讨论】:

    【解决方案2】:
    1. 选择项目目标
    2. 进入构建阶段
    3. 搜索 Protobuf
    4. 删除 Protobuf 框架
    5. 清理构建文件夹,然后构建

    对我有用

    【讨论】:

      猜你喜欢
      • 2016-01-13
      • 1970-01-01
      • 1970-01-01
      • 2021-09-14
      • 2016-02-09
      • 2019-02-08
      • 2019-03-30
      • 2010-12-27
      • 2017-05-25
      相关资源
      最近更新 更多