致命错误:格式错误或损坏的 AST 文件 - Xcode [英] fatal error: malformed or corrupted AST file - Xcode

查看:21
本文介绍了致命错误:格式错误或损坏的 AST 文件 - Xcode的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在最新版本的 Xcode 中构建我的应用程序时出现此错误:

I get this error when building my app in the latest version of Xcode:

致命错误:格式错误或损坏的 AST 文件:'无法加载模块/Users/me/Library/Developer/Xcode/DerivedData/ModuleCache/XYZYIE6ZV0OP/Darwin.pcm":找不到文件'注意:修改系统头文件后,请删除模块缓存在'/Users/me/Library/Developer/Xcode/DerivedData/ModuleCache/XYZYIE6ZV0OP'产生了 1 个错误.

fatal error: malformed or corrupted AST file: 'Unable to load module "/Users/me/Library/Developer/Xcode/DerivedData/ModuleCache/XYZYIE6ZV0OP/Darwin.pcm": file not found' note: after modifying system headers, please delete the module cache at '/Users/me/Library/Developer/Xcode/DerivedData/ModuleCache/XYZYIE6ZV0OP' 1 error generated.

当我导航到:

/Users/me/Library/Developer/Xcode/DerivedData/ModuleCache

/Users/me/Library/Developer/Xcode/DerivedData/ModuleCache

我可以看到目录XYZYIE6ZV0OP"不存在.

I can see that the directory 'XYZYIE6ZV0OP' doesn't exist.

有人知道我如何解决这个问题吗?我无法按照错误消息第二部分的建议删除目录中的任何内容,因为该目录不存在!

Does anybody know how I can resolve this? I cannot delete anything at the directory as suggested in the 2nd part of the error message as that directory doesn't exist!

推荐答案

遇到了同样的问题.清除派生数据文件夹为我解决了这个问题.在 Xcode 中,转到 Window->Organizer->Projects,选择您的项目,然后按Derived data"旁边的Delete..."按钮.

Had same problem. Clearing derived data folder solved the issue for me. In Xcode, go to Window->Organizer->Projects, select your project, and press the "Delete..." button next to "Derived data".

如果这不起作用,您可以尝试执行 Product->Clean (Cmd+Shift+k).

If this doesn't work, you can try to do a Product->Clean (Cmd+Shift+k).

这篇关于致命错误:格式错误或损坏的 AST 文件 - Xcode的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆