Just downloaded Xcode and I am trying to run a simple C++ file to make sure everything works and whenever I try to run the .cpp file I am given this: "The run destination My Mac is not valid for Running the scheme 'Scheme_Name'.
-
1just set the SDK to MacOS X 10.6.– pkc456Oct 13, 2015 at 5:36
-
1@pkc456 How do I set the SDK?– timtour97Oct 13, 2015 at 18:33
-
11) Click on the project icon in the left hand panel. 2)select Build Settings » all. 3) You'll see the option to change the SDK. img546.imageshack.us/img546/9808/picture3fh.png– pkc456Oct 14, 2015 at 4:27
-
I can only set the SDK to "macOS", I'm not able to set a version of macOS. I'm using Xcode 10.1 (10B61). The error persists with this setting.– Johannes BittnerFeb 3, 2019 at 2:06
2 Answers
happened the same to me with a project I downloaded. In my case, the solution was to change the "Base SDK" to the latest OS X in the Build Settings.
To do so, click on the project name in the navigator on the left, then on Build Settings
and in the main window you should look for Base SDK
.
If Base SDK
does not show, ensure that "All" is selected in the filter at the top of the page.
-
hm, i'm having these exact symptoms with a Library project of my own, and after xcode 7 the library won't archive w/ this same message. I also had osx10.9 in the settings, but bumping it to latests isn't helping. Dec 18, 2015 at 20:07
-
oh, I see my problem. My library has multiple targets and I was setting the Base SDK on the wrong target. this works. thank you. Dec 18, 2015 at 20:15
-
3For possible other Xcode newbies like myself, I'll elaborate on @orionelenzil 's comment above - the "targets" are shown in a drop-down on the topmost toolbar in the above screen shot, over near the left end. (Blurred out in the above screen shot.) Dec 7, 2016 at 21:32