Xcode 6: How to solve Precompile prefix Header error

生来就可爱ヽ(ⅴ<●) 提交于 2020-01-06 02:30:44

问题


I just moved an app i've been working on from Xcode 5, onto another computer running Xcode 6, (working fine on Xcode 5)

I now get the following error

I assume this was an issue with a missing .pch file, when I look into this dir i found the file but its called TMU-Prefix.pch instead of TMU_4.0-Prefix.pch

I figured my prefix header must be set incorrectly so I went in to build settings to change that and to my surprise my build settings is looking for the right file

This file which does indeed exist in my directory . . .

I'm clueless as to this error upon search I came upon this post where Xcode 6 requires creating a separate .pch file i did and yet no success

As always, Any help is much appreciated


回答1:


When you see compiler errors looking for files that exist you should straight away realise that there is a naming issue conflict somewhere in the build settings of one of your targets, this was simply the case for me : mind boggling - but this post paved the way towards the answer




回答2:


you need to check you project name (e.g Demo) and project test name (e.g DemoTests.m ) must be same. if both name are not same then rename same as to Demo




回答3:


check both the project file build settings and target file build settings.If in any of the file its is incorrectly specified you will get error.



来源:https://stackoverflow.com/questions/28576447/xcode-6-how-to-solve-precompile-prefix-header-error

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!