gpt4 book ai didi

swift - Xcode12.4 无法为 pod 目标合并 user_target_xcconfig

转载 作者:行者123 更新时间:2023-12-04 11:44:12 29 4
gpt4 key购买 nike

我一直在尝试更新 Pod,但是,每次运行 pod update 时都会收到此警告.
enter image description here
这里分别是项目和 Pod 的排除架构。
enter image description here
enter image description here
我试过的

  • 将此代码段添加到 Podfile 的顶部
  • post_install do |installer|
    installer.pods_project.build_configurations.each do |config|
    config.build_settings["EXCLUDED_ARCHS[sdk=iphonesimulator*]"] = "arm64"
    end
    end
  • 删除 Podfile.lock 和 Pods 目录并运行 pod install
  • 几乎被关注 this除了添加这个片段,因为我没有 .podspec文件。
  • s.pod_target_xcconfig = { 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' => 'arm64' }
    s.user_target_xcconfig = { 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' => 'arm64' }
    如果您有建议和提示,那就太好了。
    谢谢。
    [更新] 2021 年 2 月 23 日(太平洋标准时间)
    这个我还没弄明白,有没有人能帮我解决一下?
    我另外做的事情
  • 将此代码段添加到顶部 Podfile。
  • post_install do |installer|
    installer.pods_project.build_configurations.each do |config|
    config.build_settings["EXCLUDED_ARCHS[sdk=iphonesimulator*]"] = "arm64"
    end

    installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
    config.build_settings["ONLY_ACTIVE_ARCH"] = "YES"
    end
    end
    end
  • 试图删除 VALID_ARCHS但是,它不能从 Target 中移除。另外,将它们替换为空白。没有什么改变。

  • 好奇的
    这是 Pod 的build设置的屏幕截图。
    enter image description here Build Active Architecture OnlyRelease当前设置 No .即使我将其更改为 Yes ,它被覆盖了。将其保留为 No 是否可以? ?

    最佳答案

    在短期内,在你的 podspec 中解决它是可行的。尝试这个:

    post_install do |installer|
    installer.generated_projects.each do |project|
    project.targets.each do |target|
    target.build_configurations.each do |config|
    config.build_settings["EXCLUDED_ARCHS[sdk=iphonesimulator*]"] = "i386 arm64"
    end
    end
    end
    end
    source了解更多信息。
    从长远来看,开始要求那些库维护者停止依赖 user_target_xcconfig .
    我维护 GoogleMobileAdsMediationFacebook我们通过艰难的方式学到了这一点。 version 6.3.0.0规范已更新为设置 VALID_ARCHSpod_target_xcconfig水平而已。我们计划对 Google-Mobile-Ads-SDK 进行相同的更改在即将发布的版本中。但其他广告 SDK 也需要这样做。

    关于swift - Xcode12.4 无法为 pod 目标合并 user_target_xcconfig,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/66273418/

    29 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com