在执行npx react-native init MyProject
时,我遇到了以下错误:
✖ Installing CocoaPods dependencies (this may take a few minutes)
error Error: Failed to install CocoaPods dependencies for iOS project, which is required by this template.
这似乎与之前显示的错误有关:
checking for arm-apple-darwin-gcc... /Library/Developer/CommandLineTools/usr/bin/cc -arch armv7 -isysroot
checking whether the C compiler works... no
xcrun: error: SDK "iphoneos" cannot be located
xcrun: error: SDK "iphoneos" cannot be located
xcrun: error: SDK "iphoneos" cannot be located
xcrun: error: unable to lookup item 'Path' in SDK 'iphoneos'
XCode及其CLI似乎运行良好.
我的配置:
- MacOS Catalina 10.15.1(19B88)
- NPM 6.11.3
- react 本机0.61.4
- XCode 11.2.1(11B500)
感谢任何线索.