XCODE编译运行项目后,发现工程编译后无法运行,出现:admin管理员组文章数量:1635823
"The selected destination does not support the architecture for which the selected software is built. Switch to a destination that supports that architecture in order to run the selected software." 错误。
首先,出现该问题一般是在
${PROJECT_NAME}.xcodeproj目录的相关文件的问题,像xcschemes/xcschememanagement.plist
If you are having the same problem — deleting all the Xcode4 project data with your userid may get you up and running again…
How to go about deleting the user-specific project data
In terminal – navigate to your project directory
cd into the ${PROJECT_NAME}.xcodeproj directory
run this command: find . -name ‘*yourUserName*’
rm -rf any files or dirs that come up
Reopen Xcode4 – build and *hopefully* run your project
解决方法步骤如下:
1、在命令行中cd到你的工程文件夹下
2、cd进xcode 项目的文件夹,大致格式是:${PROJECT_NAME}.xcodeproj (注: 每一个xcode 项目其实是一个文件夹。。你如果右键点击项目文件会发现一个属性叫:show package content,其实就是浏览它的内容。。)
3、进入yourname.xcuserdatad/xcschemes 后将xcschememanagement.plist 目录删除
rm -rf ./project.xcworkspace/xcuserdata/"用户名".xcuserdatad
rm -rf ./xcuserdata/"用户名".xcuserdatad
rm -rf ./project.xcworkspace/xcuserdata/xcschemes/xcschememanagement.plist
4、把xcode关掉(command+q彻底退出啊。。记得),然后重开。*希望*能运行吧。不行就只能再google了。。
还有另一种可能原因是,出现有以下类似警告的错误提示,造成上述错误弹出窗口出现:
[WARN]Warning: Multiple build commands for output file /Developer/build/Release-iphonesimulator/
target引用了名字重复的资源
找到当前的target,展开之后,找到Copy Bundle Resources栏目,然后在里面找到重复名字的资源或本身没资源但此处确有文件的扩展名为.plist和png的文件一一移除,删除不要的那个即可
Command+Q退出重新打开工程项目即可
本文标签: 错误selectedquotxcodeArchitecture
版权声明:本文标题:解决Xcode "The selected destination does not support the architecture " 错误错误 内容由热心网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:https://m.elefans.com/dianzi/1729216819a1190522.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论