LoginSignup
8

More than 5 years have passed since last update.

Xcode 6.4 で発生する Interface Builder のエラーを回避する

Last updated at Posted at 2015-11-09

MacOS X のアップデート時なのか、Xcode 7 インストール時なのか、何時からか Xcode 6.4 でビルドが行えなくなっていました。

問題

Xcode 6.4 でビルド時にエラーが発生したり、xib や storyboard を開こうとするとクラッシュする。

2015/11/06 12:07:07.370 ibtoold[84766]: Init failed: Error Domain=IBMessageChannelErrorDomain Code=1 "Failed to communicate with Interface Builder" UserInfo=0x7f87c069ddb0 {IBAbstractPlatformToolCrashLog=

Dyld Error Message:
  Library not loaded: /System/Library/PrivateFrameworks/PepperUICore.framework/PepperUICore
  Referenced from: /Applications/Xcode6.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Overlays/Interface Builder WatchKit Tool
  Reason: image not found


Application Specific Information:
dyld: launch, loading dependent libraries
DYLD_FRAMEWORK_PATH=/Applications/Xcode6.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Overlays
DYLD_LIBRARY_PATH=
DYLD_ROOT_PATH=/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 9.0.simruntime/Contents/Resources/RuntimeRoot
DYLD_FALLBACK_LIBRARY_PATH=
, NSLocalizedDescription=Failed to communicate with Interface Builder, NSLocalizedFailureReason=Interface Builder Cocoa Touch Tool crashed: dyld: launch, loading dependent libraries
DYLD_FRAMEWORK_PATH=/Applications/Xcode6.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Overlays
DYLD_LIBRARY_PATH=
DYLD_ROOT_PATH=/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 9.0.simruntime/Contents/Resources/RuntimeRoot
DYLD_FALLBACK_LIBRARY_PATH=
}

原因

watchOS 関連のフレームワークが読み込めずにエラーが発生している。

対策

Xcode 6.4 に含まれる、PepperUICore.frameworkSockPuppetGizmo.framework のシンボリックリンクを作成する。

sudo ln -s "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 8.4.simruntime/Contents/Resources/RuntimeRoot/System/Library/PrivateFrameworks/PepperUICore.framework" /System/Library/PrivateFrameworks/PepperUICore.framework

sudo ln -s "/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 8.4.simruntime/Contents/Resources/RuntimeRoot/System/Library/PrivateFrameworks/SockPuppetGizmo.framework" /System/Library/PrivateFrameworks/SockPuppetGizmo.framework

備考

Command Line Tools のバージョンを変更することでビルドは行えるが、Xcode 6 の ibtool でビルドを行いたかったのでシンボリックリンクの対策にした。

ただし、DYLD_ROOT_PATH が iOS 9 のシミュレータランタイムとなっているのでこの対策で良いのか疑問が残る…。

どなたか、他に Xcode 7 と Xcode 6 を共存させるいい方法があれば教えて下さい。

追記

2015/12/03

別問題に遭遇しました。
Asset Catalog(xcassets) を使用していると圧縮アルゴリズムが変更されているようで、iOS 9 未満で実行すると画像が読み込めないようです。

2015-12-03 18:37:20.971 IBCocoaTouchImageCatalogTool[41965:12363149] CoreUI(DEBUG): CSIGenerator using 'LZFSE' Compression coreui version (358.200000)

Xcode 7 で追加されているオプションを Build Settings に追加してみましたが、Xcode 6.4 の actool では定義されておらずエラーとなりました。

大人しく Xcode 7 へ移行した方が良さそうです。

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
8