Interface Builder crashes when failing to load IBCocoaTouchToolFoundation

Upon trying to open or create a XIB file, Xcode 6.4 just crashes:


Application Specific Information:
ProductBuildVersion: 6E35b
ASSERTION FAILURE in /SourceCache/IDEInterfaceBuilderCocoaTouch/IDEInterfaceBuilderCocoaTouch-7703/InterfaceBuilder/Utilities/IBObjectMarshalling.m:45
Details:  Failed to launch Interface Builder Cocoa Touch Tool: Error Domain=com.apple.InterfaceBuilder Code=-1 "Encountered an error communicating with Interface Builder Cocoa Touch Tool." UserInfo={NSUnderlyingError=0x7fe220a37f30 {Error Domain=IBMessageChannelErrorDomain Code=1 "Failed to communicate with Interface Builder" UserInfo={IBAbstractPlatformToolCrashLog=

Dyld Error Message:
  Library not loaded: @rpath/IBCocoaTouchToolFoundation.framework/IBCocoaTouchToolFoundation
  Referenced from: /Volumes/VOLUME/executable_path=//Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Overlays/Interface Builder Cocoa Touch Tool
  Reason: image not found


I've uninstalled Xcode (including Xcode 7 beta) and the command-line tools, and tried reinstalling Xcode from the App Store but no luck. I'm on OS X 10.11 beta 6 but the lack of other crash reports makes me worry that there is an issue with my machine. What should be providing @rpath/IBCocoaTouchToolFoundation.framework/IBCocoaTouchToolFoundation?


Filed a report at rdar://problem/22125914 but a hacky fix would be helpful too so I don't have to use another computer just for Interface Builder.

Accepted Reply

"Fixed" it by reinstalling OS X (didn't have to delete my files or programs so that was good). It was one of the only solutions left since the issue was there even with a brand new Xcode project running on a guest account.

Replies

"Fixed" it by reinstalling OS X (didn't have to delete my files or programs so that was good). It was one of the only solutions left since the issue was there even with a brand new Xcode project running on a guest account.

Same issue here!


You reinstalled beta 6 from the recovery partition?

Yes, I believe I used the recovery partition by following the instructions here: https://support.apple.com/kb/PH18872?locale=en_US. When you reinstall OS X it will put you all the way back to OS X 10.11 beta 1 and you will have to reinstall beta 2, 3, 4, and 5. Make sure to avoid beta 6 if you are a developer!

I am sorry, but this is a joke. An Apple developer beta, a sixth beta no less,does not support its developer tools, neither the released stable version, nor unstable beta version. Who approved this for release? Would have never happened in the days of Jobs. Just a sad state of affairs.

You can also work around the issue by reinstalling the El Cap beta 5 delta (don't need to reinstall 10.11 and all the interim betas, just this delta).


Locating the delta is an exercise for the reader, but I found it by searching Twitter for "xcode 6 el capitan beta 6".


(Last time I tried to link to it my post was left in moderator limbo.)

Okay found a solution on Beta 6:


Make sure you have Xcode-beta.ap and Xcode.app both installed. Now do this on the terminal:


> sudo rm -Rvf /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform


> sudo ln -s /Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneSimulator.platform /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform


> sudo chown root /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/dyld_sim


> chmod g-w /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/dyld_sim


And you're done 🙂 Basically you've replaced the Simulator from Xcode 7 to Xcode 6 - at least now you can compile production code on your machine and even submit your updates to the App Store using Xcode 6.

By doing this - I can now run Xcode again. But I seem to have lost syntax highlighting in my projects. Are you experiencing the same?

By doing this - My Xcode 6 totally crashed,open a project or create a new one。。。

lembacon, on this thread: https://forums.developer.apple.com/thread/13170?start=105&tstart=0 has a workaround that does not involve reinstalling OS X.