I have an application built against iOS 7, but targeted for iOS 5.1 since I only have an iPad 1 available for testing. It's an all native library, with very minimal iOS dependencies. I am able to run the app on my iPad just fine, but when I try to Profile it, XCode 5 immediately changes the status to 'Finished running on iPad', and the Instruments window shows a warning saying 'This device does not support this instrument'. I see this behavior regardless of which instrument I choose from the Instruments panel.
I have tried other suggestions from similar issues posted on Stackoverflow such as
1. Cleaning my app and rebuilding
2. Restarting XCode
3. Deleting my app from the device
4. Changing the deployment target from 'iPhone/iPad' to just 'iPhone'
None of these have helped me get over this problem. Is there something fundamentally not supported in the configuration that I am trying to run ? Since the app runs correctly on the iPad, this seems like just a problem with Instruments compatibility, so I welcome any comments / suggestions on resolving this.
Thanks.
Related
I have a 7+ year old project file that started with Xcode 4, which has been
ported to Xcode 5, 7, 8, and 9.2. For all those versions of Xcode there was
a consistent method and behavior of the Run (Play) button and setting and
stopping at breakpoints.
This is an Enterprise app and I've always had the luxury of actual iPhones
and iPads to do testing (never needed to use the simulator). We recently had
to jump from Xcode 9.2 to Xcode 11.1 to support newly bought devices running
iOS 13. I've always used objective-c.
My problem is with Xcode 11.1. The Run button behaves differently, and
breakpoints are not causing the program to halt. As far as breakpoints
halting, nothing was changed in project settings relating to the
numerous accounts I've researched in Stackoverflow for breakpoints to
be ignored. And it's always worked for me before. As far as the Run button,
I'm seeing unreasonable behavior. Maybe the two issues are related which
is why I'm pairing them together.
In previous versions of Xcode, one pressed the Run button which
resulted in the following:
1. The code was compiled and built when an editing change
had been made.
2. The newly built app was installed on the device whether
or not there was a previous version of the app already
residing there.
3. The app was then executed and breakpoints were halted
upon.
In Xcode 11.1, the Run button shows a list of apps is provided to
execute. If my app does not already exist on the device, it does
not show up on the list. And none of the steps outlined above are
performed.
This is how I have to now build and run the app on a device using
Xcode 11.1 and iOS 13.1.2
To build the app I go into Product->Build For->Running. That
builds the app which is now just sitting there. To actually get
it installed on the device I have to go back to the Run button
and choose one of the available apps which in my case I choose
"Books". Before Books is started, I can see text in the status
window indicating my app is being installed on the device. Books
is then started and I press the Stop button to kill it. Then I
press the Run button again and see my app on the list. I can
then choose to run it and I see output to the debug window.
However, after my app starts running none of the breakpoints
I've set are halted upon.
Would appreciate any help you can muster. Is there a method to
compile and build and run an app similar to the old method? And
is there a reason you can think why breakpoints are not being
serviced?
Thank you.
Mike
Over the many years I've used Xcode, I never had to change the Scheme of execution. So I never even understood it's purpose. For some reason, when I downloaded the newest version of Xcode (11.1), it changed the default values for Scheme causing the Run button to launch in a different manner which I described in the post. Perhaps it's due to an extension I'm not aware of in my code dependancies as Paulw11 mentioned. But anyway, here is the way to insure your app will be launched directly and in the debugger:
Product->Scheme->Edit Scheme-> Build Configuration = Debug, Executable is set to "Your App", Debug Execution is set to checked, Launch Automatically is set to checked.
Beware Xcode may change these values when you download a new version.
I installed xcode 6 and was working on my app on simulator.
Now i have added push support it was time to start working on the device.
The problem is i cant get it to work. The device sits there and does nothing. Xcode says the app is running on the device but nothing happens.
When i click on "Running app on device" i can see its in the status of
"Validating Application "
The whole time...
I tried the solutions on SO but they are all for xcode 4 and some points about architechture and info.plist.
Checked both nothing wrong with it (testing on 5s, 7.1).
Tested other apps (got from github and so on), same problem cant run on device.
I think it has to do with xcode because all projects (big and small,old and new) don't work. I also tried on my ipad same problem.
So its not related to project or device.
Anyone has a solution ?
Removed xcode and installed it again. Works.
But to be honest since Xcode 4 this is the worst Xcode, allot of hangs and crashes. Need to force quit at least 6 times a day.
I have that problem where I updated Xamarin and Xcode to their latest stable version.
My app will run on the Simulator, but won't run on the Device. It will install, then it will crash just after the Launch Screen, and it doesn't give any Error in the IDE.
I tried on another computer where Xamarin is on the same version, but Xcode is still on the 4.X ... and it launch with success and run as it should on the device.
So, is it just a problem with Xamarin and Xcode 5 compatibility ? Can I do something to fix that problem, any tips to solve this problem will be grateful.
What might be happening (that is happening to me) is that the resulting exe is too big.
I have an app that uses servicestack. Before xcode 4.6 it worked, after xcode 5 it does not work.
With Xamarin support and some research I realized that the "estimated size" for the "archive" in organizer was bigger than 62mb. Whenever that happens my app is killed before starting.
I am in the process of slimming down servicestack, but preliminarily it is working.
Bottom line: check the size of your exe. See limitation: Max size of an iOS application
Having a strange issue with XCode 4.5 on OSX 10.8.2.
When I run an application on the mac, it doesn't launch and I get the following error in console consistently.
10/01/2013 17:26:26.478 Xcode[7884]: ERROR: Failed to create an alert for ID "enabled" based on defaults: 1
When I run an iPad/iPhone app, the simulator launches, but the app just shows a blank screen. I thought there was an issue with my apps (although very unlikely) so attempted to create a vanilla mac app and iOS app. Both experience the same issues. Running/Debugging any iPad project directly on the iPad through Xcode works however.
I've attempted to:
Delete everything in ~/Library/Developer/Xcode/DerivedData/
Delete the Xcode app and download it again from the AppStore
Delete all of my Xcode preferences
Xcode Build and stop buttons also become unresponsive so I have to force quit xcode to try again.
Nothing seems to be working, Xcode works fine however on my mac pro at work and all projects build just fine! Any help would be much appreciated!
Never mind, setting the debugger to GDB instead of LLDB seems to have fixed this. It would however be good to get an answer as to why LLDB doesn't work as the default debugger and what's changed in xcode to make it no longer work as expected.
I have an app created from sample code I found online. I hooked up my iPod touch 4G to my computer and everything worked fine, app ran.
Then I hooked up my iPhone 3G to the computer, established provisioning profiles, etc. In the organizer the device shows up as a green dot, so we're good. The name of the device is right there next to the run button so that's a good sign. But when I hit run it says "build succeeded" and then goes directly to "finished running on " but nothing shows up on the app!
I've tried this with several apps now and all work on iPod touch, but none on iPhone.
Devices are running newest operating systems, 4.2 for the iPhone, Xcode version is the newest.
I had a different question with more than likely the same answer
App built with Xcode 4.2 ios 5.0 crashing when installed on iphone with ios 4.3.5
I found the solution here
Is it possible to target older iOS versions when using Xcode 4.2 and iOS 5 SDK?
by mmorris
I had to do what he clearly explained and 1 more thing:
Set the compiler in the Project and Target Build Set to LLVM GCC 4.2
That got the app running on my older devices
I had problem to run on simulator not on device.
Tried above options but didn't work for me.
Finally, Just Resetting Simulator did the trick.
Make sure you are targeting the least iOS version and SDK that you can in the build profiles (targets, summary, Devices, Deployment target). Also, check the error console (All Output) at the bottom right and see if there's some kind of problem occurring.