Xcode4 我一向XCode 4.0.2添加项目,它就会崩溃
它给出了以下错误:Xcode4 我一向XCode 4.0.2添加项目,它就会崩溃,xcode4,Xcode4,它给出了以下错误: ASSERTION FAILURE in /SourceCache/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-269/Xcode3Sources/XcodeIDE/Frameworks/DevToolsBase/pbxcore/PBXContainerItemProxy.m:268 Details: Assertion failed: _containerPortal == [self container] || ([_
ASSERTION FAILURE in /SourceCache/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-269/Xcode3Sources/XcodeIDE/Frameworks/DevToolsBase/pbxcore/PBXContainerItemProxy.m:268
Details: Assertion failed: _containerPortal == [self container] || ([_containerPortal isKindOfClass:[PBXFileReference class]] && [(PBXFileReference *)_containerPortal container] == [self container])
Object: <PBXContainerItemProxy: 0x2017db420>
Method: -_containerPortal
Thread: <NSThread: 0x200020700>{name = (null), num = 1}
Hints: None
Backtrace:
0 0x0000000100949773 -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:messageFormat:arguments:] (in IDEKit)
1 0x000000010006d394 _DVTAssertionFailureHandler (in DVTFoundation)
2 0x000000010d4a15c7 -[PBXContainerItemProxy _containerPortal] (in DevToolsCore)
3 0x000000010d3deefb -[PBXArchivingBinding writeValueForObject:toPListArchiver:] (in DevToolsCore)
4 0x000000010d3dde4e -[PBXObject _archiveValuesForArchiveMask:toPListArchiver:] (in DevToolsCore)
5 0x000000010d40b52a -[PBXPListArchiver _archiveObject:asWeakReference:] (in DevToolsCore)
6 0x000000010d40dea8 -[PBXPListArchiver _encodeObject:forKey:asWeakReference:] (in DevToolsCore)
7 0x000000010d3df0b2 -[PBXArchivingBinding writeValueForObject:toPListArchiver:] (in DevToolsCore)
8 0x000000010d3dde4e -[PBXObject _archiveValuesForArchiveMask:toPListArchiver:] (in DevToolsCore)
9 0x000000010d4461c0 -[PBXTargetDependency writeToPListArchiver:] (in DevToolsCore)
10 0x000000010d40b52a -[PBXPListArchiver _archiveObject:asWeakReference:] (in DevToolsCore)
11 0x000000010d40e212 -[PBXPListArchiver _createPListArrayForObjectArray:asWeakReference:] (in DevToolsCore)
12 0x000000010d40ea15 -[PBXPListArchiver _encodeObjectArray:forKey:asWeakReference:] (in DevToolsCore)
13 0x000000010d3df0b2 -[PBXArchivingBinding writeValueForObject:toPListArchiver:] (in DevToolsCore)
14 0x000000010d3dde4e -[PBXObject _archiveValuesForArchiveMask:toPListArchiver:] (in DevToolsCore)
15 0x000000010d40b52a -[PBXPListArchiver _archiveObject:asWeakReference:] (in DevToolsCore)
16 0x000000010d40e212 -[PBXPListArchiver _createPListArrayForObjectArray:asWeakReference:] (in DevToolsCore)
17 0x000000010d40ea15 -[PBXPListArchiver _encodeObjectArray:forKey:asWeakReference:] (in DevToolsCore)
18 0x000000010d3df0b2 -[PBXArchivingBinding writeValueForObject:toPListArchiver:] (in DevToolsCore)
19 0x000000010d3dde4e -[PBXObject _archiveValuesForArchiveMask:toPListArchiver:] (in DevToolsCore)
20 0x000000010d40b52a -[PBXPListArchiver _archiveObject:asWeakReference:] (in DevToolsCore)
21 0x000000010d40c1b7 -[PBXPListArchiver initWithRootObject:delegate:role:] (in DevToolsCore)
22 0x000000010d40c4ac -[PBXPListArchiver initWithRootObject:delegate:] (in DevToolsCore)
23 0x000000010d3e675d -[PBXProject writeToFile:projectFile:userFile:outResultNotification:] (in DevToolsCore)
24 0x000000010d3e6d42 -[PBXProject _writeToFileSystemProjectFile:userFile:checkNeedsRevert:] (in DevToolsCore)
25 0x000000010d3e6df6 -[PBXProject writeToFileSystemProjectFile:userFile:checkNeedsRevert:] (in DevToolsCore)
26 0x000000010d3653ea -[Xcode3Project writeToFilePath:forceWrite:error:] (in Xcode3Core)
27 0x000000010051e47e -[IDEContainer _saveContainerForAction:error:] (in IDEFoundation)
28 0x00007fff8231b7d5 __NSFireTimer (in Foundation)
29 0x00007fff81173be8 __CFRunLoopRun (in CoreFoundation)
30 0x00007fff81171dbf CFRunLoopRunSpecific (in CoreFoundation)
31 0x00007fff823007c4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] (in Foundation)
32 0x00007fff8234bf36 -[NSRunLoop(NSRunLoop) runUntilDate:] (in Foundation)
33 0x00007fff83a73e0b NSCoreDragReceiveProc (in AppKit)
34 0x00007fff81a8a2c3 DoDropMessage (in HIServices)
35 0x00007fff81a8b4f2 CoreDragMessageHandler (in HIServices)
36 0x00007fff811d95e1 __CFMessagePortPerform (in CoreFoundation)
37 0x00007fff811736e1 __CFRunLoopRun (in CoreFoundation)
38 0x00007fff81171dbf CFRunLoopRunSpecific (in CoreFoundation)
39 0x00007fff84ea67ee RunCurrentEventLoopInMode (in HIToolbox)
40 0x00007fff84ea6551 ReceiveNextEventCommon (in HIToolbox)
41 0x00007fff84ea64ac BlockUntilNextEventMatchingListInMode (in HIToolbox)
42 0x00007fff83732e64 _DPSNextEvent (in AppKit)
43 0x00007fff837327a9 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] (in AppKit)
44 0x00007fff836f848b -[NSApplication run] (in AppKit)
45 0x00007fff836f11a8 NSApplicationMain (in AppKit)
46 0x0000000100000eec
/SourceCache/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-269/Xcode3Sources/XcodeIDE/Frameworks/DevToolsBase/pbxcore/PBXContainerItemProxy.m:268中的断言失败
详细信息:断言失败:_containerPortal==[self container]| |([u containerPortal是kindof类:[PBXFileReference类]]&&[(PBXFileReference*)_containerportalcontainer]==[self container])
对象:
方法:-集装箱港口
线程:{name=(null),num=1}
提示:无
回溯:
0 0x0000000100949773-[IDEAssertionHandler handleFailureInMethod:对象:文件名:行号:消息格式:参数:](在IDEKit中)
1 0x000000010006d394_DVTAssertionFailureHandler(在DVT基础中)
2 0x000000010d4a15c7-[PBXContainerItemProxy_containerPortal](在DevToolsCore中)
3 0x000000010d3deefb-[PBXArchivingBinding writeValueForObject:toPListArchiver:](在DevToolsCore中)
4 0x000000010d3dde4e-[PBXObject\u归档值ForrachiveMask:toPListArchiver:](在DevToolsCore中)
5 0x000000010d40b52a-[PBXPListArchiver\u archiveObject:asWeakReference:(在DevToolsCore中)
6 0x000000010d40dea8-[PBXPListArchiver\u编码对象:forKey:asWeakReference:(在DevToolsCore中)
7 0x000000010d3df0b2-[PBXArchivingBinding writeValueForObject:toPListArchiver:](在DevToolsCore中)
8 0x000000010d3dde4e-[PBXObject\u归档值ForrachiveMask:toPListArchiver:](在DevToolsCore中)
9 0x000000010d4461c0-[PBXTargetDependency writetopliestarchiver:](在DevToolsCore中)
10 0x000000010d40b52a-[PBXPListArchiver\u archiveObject:asWeakReference:(在DevToolsCore中)
11 0x000000010d40e212-[PBXPListArchiver\u CreatePlistarayForObjectArray:asWeakReference:](在DevToolsCore中)
12 0x000000010d40ea15-[PBXPListArchiver\u encodeObjectArray:forKey:asWeakReference:](在DevToolsCore中)
13 0x000000010d3df0b2-[PBXArchivingBinding writeValueForObject:toPListArchiver:](在DevToolsCore中)
14 0x000000010d3dde4e-[PBXObject\u归档值ForachiveMask:toPListArchiver:](在DevToolsCore中)
15 0x000000010d40b52a-[PBXPListArchiver\u archiveObject:asWeakReference:(在DevToolsCore中)
16 0x000000010d40e212-[PBXPListArchiver\u CreatePlistarayForObjectArray:asWeakReference:](在DevToolsCore中)
17 0x000000010d40ea15-[PBXPListArchiver\u encodeObjectArray:forKey:asWeakReference:](在DevToolsCore中)
18 0x000000010d3df0b2-[PBXArchivingBinding writeValueForObject:toPListArchiver:](在DevToolsCore中)
19 0x000000010d3dde4e-[PBXObject\u归档值ForrachiveMask:toPListArchiver:](在DevToolsCore中)
20 0x000000010d40b52a-[PBXPListArchiver\u archiveObject:asWeakReference:(在DevToolsCore中)
21 0x000000010d40c1b7-[PBXPListArchiver initWithRootObject:委托:角色:](在DevToolsCore中)
22 0x000000010d40c4ac-[PBXPListArchiver initWithRootObject:委托:](在DevToolsCore中)
23 0x000000010d3e675d-[PBX项目写入文件:项目文件:用户文件:输出结果通知:](在DevToolsCore中)
24 0x000000010d3e6d42-[PBXProject\u writeToFileSystemProjectFile:userFile:checkNeedsRevert:](在DevToolsCore中)
25 0x000000010d3e6df6-[PBXProject writeToFileSystemProjectFile:userFile:checkNeedsRevert:](在DevToolsCore中)
26 0x000000010d3653ea-[Xcode3Project writeToFilePath:forceWrite:错误:](在Xcode3Core中)
27 0x000000010051e47e-[IDEContainer\u saveContainerForAction:错误:](在IDEFoundation中)
28 0x00007fff8231b7d5\uu NSFireTimer(基础中)
29 0x00007fff81173be8\uuu CFRunLoopRun(在CoreFoundation中)
30 0x00007fff81171dbf CFRunLoopRunSpecific(在CoreFoundation中)
31 0x00007fff823007c4-[nsrunlop(nsrunlop)运行模式:beforeDate:(在基础中)
32 0x00007fff8234bf36-[nsrunlop(nsrunlop)runUntilDate:](在基础中)
33 0x00007fff83a73e0b NSCoreDragReceiveProc(在应用套件中)
34 0x00007fff81a8a2c3 DoDropMessage(在他的服务中)
35 0x00007fff81a8b4f2 CoreDragMessageHandler(在他的服务中)
36 0x00007fff811d95e1\uuu CFMessagePortPerform(在CoreFoundation中)
37 0x00007fff811736e1\uuuu CFRunLoopRun(在CoreFoundation中)
38 0x00007fff81171dbf CFRunLoopRunSpecific(在CoreFoundation中)
39 0x00007fff84ea67ee RunCurrentEventLoopInMode(在HIToolbox中)
40 0x00007fff84ea6551接收下一个EventCommon(在HIToolbox中)
41 0x00007fff84ea64ac块直到ExtEventMatchingListinMode(在HIToolbox中)
42 0x00007fff83732e64 _dpsnextent(在应用套件中)
43 0x00007fff837327a9-[N应用程序下一个EventMachingTask:untilDate:inMode:dequeue:(在应用程序工具包中)
44 0x00007fff836f848b-[N应用程序运行](在应用程序工具包中)
45 0x00007fff836f11a8非应用程序主程序(在应用程序套件中)
46 0x0000000100000eec
显然这是由于新版本的XCodeProjects。我找到了一个解决方法,即预编译导致问题的库,然后使用链接器链接到.a文件。我还必须将.a库复制到DerivedData路径中
真正的解决方案是删除该项目,并用新版本XCode的更新项目替换它。更糟糕的是,尽管我删除了该项目,但在我的案例中,崩溃已经多次发生。
我通过手动编辑project.pbxproj(在.xcodeproject文件中)修复了此问题。我通过返回project.pbxproj的备份修复了此问题。之后,我删除了导致问题的库(仅供参考)。再次将库添加到项目中并删除了衍生数据