卸載了xcode後,重新安裝,使用時,出現以下報信息:
/xcrun:1:1: sh -c '/Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild -sdk /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.5.sdk -find pngcrush 2> /dev/null' failed with exit code 17920: (null) (errno=No such file or directory)
打開xcode的偏好設置項:
Locations->Command line Tools選擇一下
如果沒有,就去蘋果官方開發者網站下載一下對應的命令行安裝一下:
https://developer.apple.com/download/more/
安裝完成後,再按照第二步選擇一下命令行即可。
或者使用以下命令亦行:sudo xcode-select --switch /Library/Developer/CommandLineTools/