我正在尝试使用 Carthage 将 Realm 安装到我的项目中。它以前可以工作,但在切换到新的 MacBook Pro(15 英寸,2018 年,TouchBar)之后我收到以下错误,
carthage update --no-use-binaries --platform iOS
*** Fetching realm-cocoa
*** Checking out realm-cocoa at "v3.13.0"
*** xcodebuild output can be found in /var/folders/m4/1z0tvn6d67q2rqwcjvndy80m0000gn/T/carthage-xcodebuild.2vfx4v.log
*** Building scheme "Realm" in Realm.xcworkspace
Could not find any available simulators for iOS
我已经尝试卸载和重新安装 Carthage (0.31.2) 并按照这些答案中给出的步骤进行操作,
xcrun simctl list devices --json
{
"availability" : "(available)",
"state" : "Shutdown",
"isAvailable" : true,
"name" : "iPad Pro",
"udid" : "94790E33-EA0A-40B4-BA0A-19CC8D976A6F",
"availabilityError" : ""
}
调试迦太基
(lldb) po devices[latestOSName]?.first { $0.isAvailable }
▿ Optional<Simulator>
▿ some : Simulator
- isAvailable : true
- name : "iPhone 5s"
- udid : 87A9C887-034C-44A8-8F30-C90AF9ACCBCC
(lldb) po sdk.platform
XCDBLD.Platform.iOS
(lldb) po sdk.platform.rawValue
"iOS"
看起来这个问题仍然存在。有没有办法解决这个问题以在最新的 Xcode 版本上工作?