iphone - 基于 PhoneGap 的 iOS 应用程序缺少基本 SDK

标签 iphone ios cordova

我已经安装了 PhoneGap iOS 的库并创建了一个新项目,但是当我运行该应用程序时,出现错误 Base SDK missing。这是为什么?

编辑1

应用 mAc 回复后出现 230 错误这些是一些错误:

/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPDFContext.h:60:23 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGPDFContext.h:60:23: error: expected function body after function declarator


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250:91 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250:91: error: expected a type


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:256:86 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:256:86: error: expected a type


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:258:114 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:258:114: error: expected a type


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:187:31 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:187:31: error: unknown type name 'UIApplicationState'


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:190:4 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:190:4: error: expected a type


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:191:28 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:191:28: error: expected a type


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:202:45 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:202:45: error: expected a type


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:206:4 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:206:4: error: expected a type


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UITextView.h:82:22 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UITextView.h:82:22: error: unknown type name 'UIDataDetectorTypes'


/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIWebView.h:54:22 /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIWebView.h:54:22: error: unknown type name 'UIDataDetectorTypes'


/Users/Ahmed/Documents/PhoneGapLib/Classes/Camera.h:56:10 /Users/Ahmed/Documents/PhoneGapLib/Classes/Camera.h:56:10: error: cannot find protocol declaration for 'UIPopoverControllerDelegate'; did you mean 'UITabBarControllerDelegate'?


/Users/Ahmed/Documents/PhoneGapLib/Classes/Camera.m:24:3 /Users/Ahmed/Documents/PhoneGapLib/Classes/Camera.m:24:3: error: use of undeclared identifier 'UIUserInterfaceIdiomPhone'; did you mean 'UIUserInterfaceIdiom'?

最佳答案

我想你已经导入了一个项目...

请参阅选择您的项目并转到其信息 -> 构建选项卡 -> 体系结构 -> 在 Base SDK 中选择最新的 iOS -> 保存并关闭。现在选择模拟器(默认选择设备)。 然后运行该应用程序。

编辑:-

可能是 Xcode 3.2.4 或 SDK 配置中的错误。

尝试在您的build设置预处理器宏中放置这样一行:

-D__IPHONE_OS_VERSION_MIN_REQUIRED=040100 

-D__IPHONE_OS_VERSION_MIN_REQUIRED=030103

您可以 Check Here也关于你的问题。

希望对您有所帮助:) 再见

关于iphone - 基于 PhoneGap 的 iOS 应用程序缺少基本 SDK,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8323352/

相关文章:

iphone - 为什么 Apple 的 SDK 文档不涵盖 UI*?

ios - SwiftUI ForEach 未更新 ObservableObject 类数组的以下更改

ios - "Missing __block type specifier"重构代码后编译错误但重构前正常

android - 是否有一个 Android intent-filter 在用户切换到应用程序时触发?

ios - Apache cordova/phonegap 如何从 config.xml 启用功能

iphone - 使用自动布局子类化 MKAnnotationView

iPhone:无法从 uitabbaritem 读取徽章值

ios - 如何使用 Alamofire 下载文件?

html - 512mb 内存设备上 Android 版 Chrome 中的渐变绘制问题

iphone - 在 Google map 上显示某个区域?