Why does my app work in the simulator but get stuck on the splash screen when I run it on my iPhone?

StackOverflow https://stackoverflow.com/questions/9350016

  •  27-10-2019
  •  | 
  •  

문제

My app runs fine on the simulator. However, when I run it on my iPhone, it gets as far as displaying the splash screen and then just stays there. It's an iPhone 3GS and the software version is 5.0.1. That's what happens when Debugger = None. When Debugger = GDB, I get an error message, 'Thread 1: Program received signal: "SIGABRT"', which I have learned can mean almost anything. I'm running Xcode 4.2.1.

I'm coming off a long hard night of battling with this error message, which appeared seemingly out of nowhere in a stable mature app. I tried to roll back with time machine, I deleted the Derived data for my project in Organizer a few times and did some of the other stuff recommended in this thread.

XCode 4 hangs at "Attaching to (app name)"

It got ugly. For a while, I couldn't even reboot my machine. Eventually, I was able to relaunch finder and suddenly the Simulator was working again. Two more pieces of information, I used to have to click allow in two dialog boxes when running on my phone but now it's only one (the one about code signing, I forget what the other one was about). Second, I find all the build architecture target stuff confusing but I set all my Base SDKs to be latest iOS. Lastly, I tried Product --> Clean and then Build but that didn't fix it. As you may have gathered, I'm getting my butt kicked. Any help would be much appreciated.

Dessie

도움이 되었습니까?

해결책

Many times I have experienced Xcode going "crazy" with a physical device connected. At times I saw the behavior you describes; other the app simply refused to start;

In all of those cases, I could fixed it in either of two ways:

  1. disconnect the iphone and connect it again;

  2. reboot the device.

다른 팁

This is a very common problem that is easily fixable.

1) remove the app from the device

2) reboot the device

3) close Xcode and you must restart, logging out will not work

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top