我正在运行Xcode 4.6.1,使用最新的SDK版本,可以成功构建项目,但在尝试运行时会发生崩溃。以下是崩溃报告的开头部分。
Process: Xcode [13573]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 4.6.1 (2067)
Build Info: IDEApplication-2067000000000000~2
App Item ID: 497799835
App External ID: 14581035
Code Type: X86-64 (Native)
Parent Process: launchd [278]
User ID: 501
Date/Time: 2013-04-08 17:57:47.633 +0300
OS Version: Mac OS X 10.8.3 (12D78)
Report Version: 10
Interval Since Last Report: 39613 sec
Crashes Since Last Report: 3
Per-App Interval Since Last Report: 1751 sec
Per-App Crashes Since Last Report: 2
Anonymous UUID: DC5CB8D0-2A9C-75E6-5631-42D5362B172F
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 4H512
UNCAUGHT EXCEPTION (NSInvalidArgumentException): -[__NSCFString alloc]: unrecognized selector sent to instance 0x4009ce3e0
UserInfo: (null)
Hints: None
Backtrace:
0 0x00007fff8ea76aee __exceptionPreprocess (in CoreFoundation)
1 0x00007fff867863f0 objc_exception_throw (in libobjc.A.dylib)
2 0x00007fff8eb0d40a -[NSObject(NSObject) doesNotRecognizeSelector:] (in Core Foundation)
正在构建和编译的代码来自Xcode中命令行工具模板
#import <Foundation/Foundation.h>
int main(int argc, const char * argv[])
{
@autoreleasepool {
// insert code here...
NSLog(@"Hello, World!");
}
return 0;
}