Duplicated target: Xcode cannot run using the selected destination

倾然丶 夕夏残阳落幕 提交于 2019-12-10 17:27:35

问题


(OS X, not iOS): "Choose a destination with a supported architecture in order to run on this system"

Fixed the copied .plist in the Build settings, removed spaces from the new product name. Can't find any difference with the original target's settings, still this dreaded error. Any ideas?


回答1:


I got this error when I opened an old project under Xcode 4.5. The problem: The build setting were set to Standard Architecture, which means 64bit and 32 bit, while the minimum deployment target was set to OS X 10.4.

Setting the minimum deployment target to OS X 10.5 fixes the problem.




回答2:


When i faced this issue, on top of the xcode window i changed My Mac 64-bit to My Mac 32-bit. It worked for me.




回答3:


For me it was a mismatch between the filename of the executable, as specified by "Product Name" in the target build settings, and the executable filename indicated in the Info.plist. In fact, when you duplicate a target, you get a "copy" suffix that you usually change right away, and this may lead to some mistakes.

An additional indication of this mismatch can be seen when selecting the product app in Xcode, and opening it in the Finder. If the app icon is overlayed with a kind of "stop" sign, here it is, your app isn't executable.




回答4:


If everything looks alright, one last thing that you should check contents of your app. Most probably application name Info.plist file does not match what you have in your build configuration.




回答5:


With Xcode 4.5.2. (4G2008a) this issue has gone away, apparently. I can now make a duplicate of the original target, fix the product name, and get a properly running application.




回答6:


I started getting the same thing. I did a Clean and it seems to have fixed it. Lion/Xcode 4.6.2




回答7:


I got the same error message after accidentally copying a binary to /usr/local/bin. The binary was "manually" generated by Makefile - the building process of Xcode (5.1) was configured to place the binary in /usr/local/bin too. Removing the manually generated file and starting the build again fixed the problem.



来源:https://stackoverflow.com/questions/12724786/duplicated-target-xcode-cannot-run-using-the-selected-destination

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!