Search code examples
rubymotion

RubyMotion fresh project gives error dlopen(/Applications/Xcode.app/Contents/Developer/../Frameworks/libswiftCore.dylib, 2): image not found


An existing or new project with RubyMotion gives the following error dlopen(/Applications/Xcode.app/Contents/Developer/../Frameworks/libswiftCore.dylib, 2): image not found and simulator does not open


Solution

  • System details - Mojave - Xcode 11.1 - Latest public Rubymotion from the website

    • Launch Xcode up and accept any terms and let it download any tools it thinks it needs to start up
    • run sudo xcodebuild -license
    • run sudo xcode-select --install && sudo xcode-select --reset make sure you're all up to date (I don't know if the installer does this already, but it doesn't hurt) sudo motion update motion repo

    Then for above error: dlopen(/Applications/Xcode.app/Contents/Developer/../Frameworks/libswiftCore.dylib, 2): image not found or objc[98906]: Class __SwiftNativeNSIndexSetBase is implemented in both /usr/lib/swift/libswiftCore.dylib (0x7fff924d4e98) and /Applications/Xcode.app/Contents/Frameworks/libswiftCore.dylib (0x1058f3f20)

    This copy of libswiftCore.dylib requires an OS version prior to 10.14.4. run sudo cp -r /usr/lib/swift/*.dylib /Applications/Xcode.app/Contents/Frameworks sudo touch /Applications/Xcode.app/Contents/Frameworks/.swift-5-staged