Xcode 11.0 Beta 4构建并运行,但无法存档 [英] Xcode 11.0 Beta 4 Builds and Runs, but can't Archive
问题描述
我的Swift项目可以正常构建和运行,但是由于以下警告而导致的每次归档尝试均失败,并显示错误:
My Swift project builds and runs normally, but fails every attempt to Archive with errors, caused by the following warnings:
Could not find or use auto-linked library 'swiftFoundation'
Could not find or use auto-linked library 'swiftMetal'
Could not find or use auto-linked library 'swiftDarwin'
Could not find or use auto-linked library 'swiftUIKit'
Could not find or use auto-linked library 'swiftCoreFoundation'
Could not find or use auto-linked library 'swiftObjectiveC'
Could not find or use auto-linked library 'swiftDispatch'
Could not find or use auto-linked library 'swiftCoreImage'
Could not find or use auto-linked library 'swiftQuartzCore'
Could not find or use auto-linked library 'swiftCoreGraphics'
Could not find or use auto-linked library 'swiftCore'
- 此问题似乎密切相关,但所提出的解决方案似乎都没有帮助.
- 错误显示在问题导航器中的此Pod 下.
- 我能够在Xcode 11.0 Beta(1)中将该项目存档.
- Xcode 10.2.1陷入了对该项目进行编译和索引的工作.
- This issue seems to be closely related, yet none of the proposed solutions seem to be helpful.
- Errors appear under this Pod in Issue Navigator.
- I was able to Archive this project in Xcode 11.0 Beta (1).
- Xcode 10.2.1 gets stuck compiling and indexing this project.
推荐答案
我遇到了同样的问题,它似乎是由Xcode beta发行说明中的已知位码问题引起的:
I've been running into the same issue, and it looks to be caused by the known bitcode issue in the Xcode beta release notes:
使用启用位码"构建设置设置为是"的包含Swift代码的目标,当使用 存档动作. (52804818)
Targets that contain Swift code with the Enable Bitcode build setting set to Yes fail to link correctly when built with the Archive action. (52804818)
解决方法:使用以下方法添加自定义构建设置: 名称LD_VERIFY_BITCODE,并将其设置为NO.给自己做个笔记 解决此问题后删除此自定义生成设置.
Workaround: Add a custom build setting with the name LD_VERIFY_BITCODE, and set it to NO. Make a note to yourself to delete this custom build setting once this issue is resolved.
您将需要添加一个用户定义的构建设置,因为它不会显示为常规的构建设置.单击构建设置"中的+,添加一个:
You will need to add a User-Defined Build Setting since it doesn't show up as a normal Build Setting. Click the + In your Build Settings to add one:
添加用户定义的设置后,一直滚动到构建设置的底部,找到刚添加的设置,然后按如下所示对其进行修改.
After Adding A User-Defined Setting, scroll all the way to the bottom of your build settings to find the one you just added, then modify it like so.
这篇关于Xcode 11.0 Beta 4构建并运行,但无法存档的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!