RubyMotion 新项目给出错误 dlopen(/Applications/Xcode.app/Contents/Developer/../Frameworks/libswiftCore.dylib, 2): image not found

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

使用 RubyMotion 的现有或新项目出现以下错误 dlopen(/Applications/Xcode.app/Contents/Developer/../Frameworks/libswiftCore.dylib, 2): image not found 模拟器打不开

系统详细信息 - Mojave - Xcode 11.1 - Latest public Rubymotion from the website

  • 启动 Xcode 并接受任何条款并让它下载它认为需要启动的任何工具
  • 运行 sudo xcodebuild -license
  • 运行 sudo xcode-select --install && sudo xcode-select --reset 确保你都是最新的(我不知道安装程序是否已经这样做了,但它没有坏处) 须藤运动更新 运动回购

然后针对上面的错误: dlopen(/Applications/Xcode.app/Contents/Developer/../Frameworks/libswiftCore.dylib, 2): image not found 要么 objc[98906]: Class __SwiftNativeNSIndexSetBase is implemented in both /usr/lib/swift/libswiftCore.dylib (0x7fff924d4e98) and /Applications/Xcode.app/Contents/Frameworks/libswiftCore.dylib (0x1058f3f20)

此 libswiftCore.dylib 副本需要 OS 10.14.4 之前的版本。 运行 sudo cp -r /usr/lib/swift/*.dylib /Applications/Xcode.app/Contents/Frameworks sudo touch /Applications/Xcode.app/Contents/Frameworks/.swift-5-staged