xcode pbxcp 问题,找不到文件,但肯定存在

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/5642633/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-09 03:53:11  来源:igfitidea点击:

pbxcp issue, file not found but it's definitely there

iphonexcode

提问by DanBroChill

So I've been working on different images for my app, seeing how it looks, replacing it...all has been well until earlier I replaced a file (checkmark.png) with an updated version I made, now when I build I get pbxcp: checkmark.png: no such file or directory. I have removed the file and re-added multiple times, I've renamed the file and replaced every instance of the file in my code with the updated name. No matter what I can't get rid of this error, all the googling I do ends up with a lot of unanswered posts, some people saying to "Clean" the project, I've tried everything I can and can't get rid of this error. Anyone have any ideas?

所以我一直在为我的应用程序处理不同的图像,看看它的外观,替换它......直到早些时候我用我制作的更新版本替换了一个文件(checkmark.png),现在当我构建我得到pbxcp: checkmark.png: no such file or directory。我删除了该文件并重新添加了多次,我重命名了该文件并用更新后的名称替换了代码中文件的每个实例。无论我无法摆脱这个错误,我所做的所有谷歌搜索最终都会得到很多未答复的帖子,有些人说要“清理”项目,我已经尽我所能,但无法摆脱这个错误。谁有想法?

采纳答案by amattn

Is this xcode 4? If so this might apply:

这是xcode 4吗?如果是这样,这可能适用:

XCode - File not found but build successful

XCode - 未找到文件但构建成功

回答by user3017198

Go to targets in app->built phases->copy bundle resources->remove image in red color and add one u need this will solve your error thanks to DanBroChill

转到应用程序中的目标-> 构建阶段-> 复制捆绑资源-> 删除红色图像并添加您需要的图像,这将解决您的错误,感谢 DanBroChill

回答by eSeverus

Here is temporary solution:

这是临时解决方案:

1.Change location type from Relative to Groupto Absolute Path.

1. 将位置类型从相对到组更改为绝对路径

2.Again locate file.

2.再次定位文件。

3. Build... should be Succeeded.

3. Build... 应该是成功的

It works in my project so I hope it helps.

它适用于我的项目,所以我希望它有所帮助。