重命名项目后找不到共享的内部框架 [英] Shared internal framework not found after renaming project

查看:87
本文介绍了重命名项目后找不到共享的内部框架的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个名为Motorcycle的快速Xcode项目,它有一个内部框架,这些内部框架在称为MotorcycleKit的目标之间共享.将项目重命名为Rollerblades之后,我在项目概述中看到了RollerbladesKit而不是MotorcycleKit.在import MotorcycleKit上找到并替换为import RollerbladesKit并运行应用程序后,我在import RollerbladesKit上收到未找到模块错误.如何解决此错误?

I have a swift Xcode project say named Motorcycle and it has an internal framework shared among targets called MotorcycleKit. After I rename my project to Rollerblades I see in the project overview I now have a RollerbladesKit instead of MotorcycleKit. After doing a find and replace on import MotorcycleKit to import RollerbladesKit and running the app I get a module not found error on my import RollerbladesKit. How do I fix this error?

推荐答案

Xcode重命名功能存在一个错误,即如果共享内部框架的名称具有名称,则该名称会将共享内部框架的项目名称重命名为新项目名称的确切文字.其中的原始项目.所以从问题上讲. MotorcycleKit的名称中包含Motorcycle,并且用Rollerblades(而不是RollerbladesKit)代替.您可以通过转到框架的Build Settings > Packaging > Product Name并在此处更正名称的方式来解决此问题,在这种情况下,可以通过在其后附加'Kit'来实现.

The Xcode rename function has a bug where it renames shared internal framework's Project Name to the exact literal of the new project name if the shared internal framework's name has the name of the original project in it. So from the question. MotorcycleKit has Motorcycle in its name and it gets replaced with Rollerblades instead of RollerbladesKit. You can fix this by going to your framework's Build Settings > Packaging > Product Name and correcting the name there, in this case by appending it with 'Kit'.

这篇关于重命名项目后找不到共享的内部框架的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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