重新安装未找到UIKit和Foundation框架后,iOS SDK崩溃了 [英] iOS SDK broken ever after reinstall UIKit and Foundation frameworks not found

查看:491
本文介绍了重新安装未找到UIKit和Foundation框架后,iOS SDK崩溃了的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于pch文件,我收到以下错误:

For the pch file I get these errors:

/Users/matt/Programming/iPhone Monkey Curling lite/iPhone_Monkey_Curling_Prefix.pch:6:34: error: Foundation/Foundation.h: No such file or directory
/Users/matt/Programming/iPhone Monkey Curling lite/iPhone_Monkey_Curling_Prefix.pch:7:24: error: UIKit/UIKit.h: No such file or directory

这是默认情况下的文件。

Here's the file as it is by default.

//
// Prefix header for all source files of the 'iPhone Monkey Curling' target in the 'iPhone Monkey Curling' project
//

#ifdef __OBJC__
#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>
#endif

我重新安装了xcode和iOS SDK,但没有解决问题。将iAd框架添加到我的某个项目后发生此问题,但我的所有项目都不会编译。

I reinstalled xcode and the iOS SDK but that did not fix the problem. This problem occurred after adding the iAd framework to one of my projects but all of my projects wont compile.

我正在使用最新的SDK(4.1)。

I'm using the latest SDK (4.1).

框架在项目中。出于某种原因,当我尝试添加新框架时,它会在iOS项目中列出OSX。

The frameworks are there in the project. For some reason when I try to add a new framework it lists the OSX ones in an iOS project.

感谢您的帮助。

推荐答案

在Apple开发人员论坛上,我设法获得了针对此问题的帮助。事实证明,构建选项设置为奇怪的东西。

On the Apple developer forums I managed to get help on pin-pointing the issue. It turns out somehow a build option was set to something odd.

这是框架搜索路径选项。如果有人遇到类似的问题,请确保这是空的。

It was the "Framework Search Paths" option. Make sure this is empty if anyone has a similar problem.

这篇关于重新安装未找到UIKit和Foundation框架后,iOS SDK崩溃了的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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