Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MacOS app does not run on the Xcode simulator

Tags:

xcode

macos

I've installed Xcode 4.2.1 on Mac OS X Lion.

When I create a new (Mac OS X Cocoa) project and I click "Run", Xcode says build succeeded, but doesn't run the project. No errors, but no application either.

When I do exactly the same thing on another Mac (but with OS X Snow Leopard and Xcode 4.0.1 installed), the created app starts bouncing in the dock and shows an empty window, like I would expect.

When I look in the Console, there seems to be nothing strange going on. I tried reinstalling Xcode, deleting everything related to Xcode, but still no luck.

Anyone got an idea what could be the problem?

(I tried running an existing project which used to work, but that didn't show anything either)

Thanks.

like image 301
Bas Avatar asked Nov 23 '11 15:11

Bas


People also ask

How do I run Xcode simulator on Mac?

The basic way to open a list of simulators is to use Xcode -> Window -> Devices and Simulators. Here you can create and manage all available simulators. But you cannot run them directly. You need to build your application on the simulator, and then you can run it.

How do I enable simulator in Xcode?

Open Xcode and click Menu > Xcode > Preferences > Select Components, and then choose the simulator version you want to download.

Can you run an IPA file on a simulator?

Just like an APK (Android Application Package) file can be installed on Android devices, an IPA file can be used for testing iOS applications. You can even push it to the app stores to publish your app. You can think of an IPA file like a simple ZIP file.


2 Answers

I had a similar problem with Xcode 4.5.2.

To fix it I had to go to the menu Product > Edit Scheme... > Select "Run " (in the sidebar) > Info (tab). In here is a drop down box labeled Executable, select it and choose your app that you wish to launch when the Run button is clicked.

like image 68
Chad Marmon Avatar answered Nov 07 '22 01:11

Chad Marmon


I messed up my settings and had this same issue - builds the app but doesn't launch (either in the simulator or the device).

The answer Product > Edit Scheme got me half way there - then choose Run {your app} on the left. There is a launch Automatically radio button to check: enter image description here

like image 22
cardmagik Avatar answered Nov 07 '22 00:11

cardmagik