问题
Xcode编译项目报Executable Not Found
的错误。
Details
Details
Executable Not Found
Domain: DVTMachOErrorDomain
Code: 5
Recovery Suggestion: /Users/xxx/Library/Developer/Xcode/DerivedData/xxx-dofplyfxahohsphaipnbzdggryec/Build/Products/Debug-iphonesimulator/xxx.app is not a valid path to an executable file. Please rebuild the project to ensure that all required executables are created. Check your project settings to ensure that a valid executable will be built.
--
System Information
macOS Version 11.5.1 (Build 20G80)
Xcode 12.5.1 (18212) (Build 12E507)
Timestamp: 2021-08-27T07:20:36+08:00
解决
MacBookPro M1
Xcode项目,TARGET -> Build Settings, search ‘VALID’.
设置 VALID_ARCHS 的值,如果使用模拟器编译的话,添加 x86_64,如果使用真机编译的话设置成arm64。
参考
【参考】
我的项目里能找到VALID_ARCHS的设置,有些项目是没有的,没有的话就找找其他解决办法吧。