Xcode 10,未构建Pod无法构建项目

编程入门 行业动态 更新时间:2024-10-27 14:30:27
本文介绍了Xcode 10,未构建Pod无法构建项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

更新为支持ios12 的最新Xcode之后,我无法构建我的项目似乎没有任何Pod正在编译。 我收到未知导入错误,例如找不到文件(例如未找到 SDWebImage / UIImageView + WebCache.h文件)

After updating to the latest Xcode to support ios12 I can't build my project It seems that none of the pods are being compiled. I'm getting an error for unknown import such as "file not found" (ex 'SDWebImage/UIImageView+WebCache.h' file not found)

(如果我评论与此相关的所有内容,则只会显示不存在的下一个软件包的错误)。

(if I comment everything related to this, it's just showing an error for the next package that does not exist)

对于从pod安装的插件。

for plugins installed from pod.

如果我添加pod方案并对其进行编译,然后编译我的项目,则所有导入都可以正常工作,但是对于每个软件包,我都会收到此编译器错误:

if I add the pod scheme and compile it, and then compile my project all the imports are working fine but then I get this compiler error for every package:

显示最近的消息

:-1: ignoring file /Users/administrator/Library/Developer/Xcode/DerivedData/XXXProject- ajmnddfiwycmqihdrqgzcltbrovs/Build/Products/Debug- iphonesimulator/Pods_XXXProject.framework/Pods_XXXProject, file was built for archive which is not the architecture being linked (i386): /Users/administrator/Library/Developer/Xcode/DerivedData/XXXProject- ajmnddfiwycmqihdrqgzcltbrovs/Build/Products/Debug- iphonesimulator/Pods_XXXProject.framework/Pods_XXXProject

我的pod文件非常简单,我的项目有3个扩展名在更新前工作正常。

My pod file is very simple, my projects have 3 extensions It worked fine before the update.

我尝试删除,安装几次,将吊舱更新为1.5.3 似乎没有任何效果。 (甚至在pod beta版本1.6中也尝试过)

I've tried removing, installing few times, updated my pod to 1.5.3 Nothing seems to work. (tried even with the pod beta version 1.6)

对旧版和新系统版本均进行了相同的错误尝试。

Tried both Legacy and New System build getting same error for both.

在项目构建阶段,一切似乎都很好,应该将其复制。 (使用use_frameworks!)

In the project build phases, everything seems fine and should be copied. (using use_frameworks!)

这是我的Podfile的样子

This is how my podfile looks like

source 'github/CocoaPods/Specs.git' use_frameworks! target ‘XXXXX’ do pod 'GoogleAnalytics' pod 'Firebase/Core' pod 'Firebase/Messaging' pod 'FBAudienceNetwork' pod 'FBSDKLoginKit' pod 'Fabric', '~> 1.7.6' pod 'Crashlytics', '~> 3.10.1' pod 'AccountKit' pod 'SDWebImage', '~> 4.0' pod 'BEMCheckBox' end

任何主意是什么问题?

Any ideas what's wrong?

推荐答案

这是您以前的缓存存储在派生数据文件夹中的问题。

This is the problem of your previous cache store in the derived data folder.

转到DerivedData文件夹。 关闭XCode。 从DerivedData文件夹中删除您的应用程序。 重新打开XCode,清理项目并再次运行。

Go to the DerivedData folder. Close XCode. Delete your apps from DerivedData folder. Reopen XCode, clean project and run again.

XCode首选项>位置>派生数据(单击目录路径中的右侧图标,它将打开DerivedData文件夹)

XCode preference > Locations > Derived Data (click right side icon in the directory path, it will open DerivedData folder)

从左侧的项目导航器中选择您的广告连播。 >选择目标。 > 选择构建设置。 >仅将活动架构构建为否

Select your pod from the left project navigator. > Select Target. > Select "Build Settings". > Build Active Architecture Only to No

更多推荐

Xcode 10,未构建Pod无法构建项目

本文发布于:2023-11-26 06:10:16,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1632944.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:项目   Xcode   Pod

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!