Remove iPad sources in XCode. - iphone

In xCode, I switched my target settings to universal out of curiousity. Then I switched it back to iPhone. When I load up my app in the iPad under universal and iPhone targets, the app crashes. I suspect it might have something to do with the added files for iPad support. How can i remove the iPad target entirely from my app? The only devices I want to support is the iPhone and the iPod.

Have you tried cleaning your project, then building?

Related

Deploy in an iPad as iPhone

I am developing one application for iPad and iPhone. The problem is that I only have one iPad. I need to develop in a physical device cause I have some libraries inside the project that only works in device.
Are there any way to deploy in my iPad as an iPhone to check if the application code is working fine?
I have a jailbroken device.
Thanks!!
In Xcode select your target and then the Summary tab. Change the Devices value from Universal to iPhone. Now build and run your app on your iPad. It will run in iPhone compatibility mode on the iPad.
Don't forget to put that option back to Universal before shipping the app to Apple.
One limitation is you can't test to see if your app works on the 4" devices. The iPhone compatibility mode only works in 3.5" mode.

Universal app disable ipad temporarly

I have created a universal app but would like to temporarly disable ipad until I have finished developing the ipad version. Reason is I would like to submit my iphone app and later work on the ipad version.
At the moment it automatically calls CaveConditionsAppDelegate_iPad.h/m when starting with ipad...
any idea how to do that?
In your build settings change the Targeted Device Family to iPhone only.
Beware that if you've released a version for iPad already, you can't drop support for it later.
From Comments:
Solution was to remove the "Main nib file basename (ipad)" from the plist.

Upgrade Current Target to IPhone Not IPad

I currently have an ipad app and would now like to turn it into a universal app for both iPad and iPhone. The problem is I cant seem to find the feature to upgrade my iPad app to universal. There is an option to go from iPhone to iPad but not the other way around.
Any ideas?
Thanks
You can just add a new target and chose what kind of devices you want to deploy on:
iPhone, iPad or Universal
See the screenshot below:

Why does XCode say that my iPhone app is only able to run on iPad?

I have a project in XCode with two targets. One target is for the iPhone only and the other is for iPad only.
The iPad target works as expected, but the iPhone target does not.
If I try to run it in the simulator, it starts the iPad simulator every time, but in iPhone compatibility mode with the 2x button.
If I try to run in on my iPhone 4 device, I get this message:
Can’t install application. The application at /Users/jacob/Documents/code/Projects/TVGuide/build/Debug-iphoneos/TVGuidePlus.app can only be installed on iPads.
This is XCode 3.2.6 and the iOS 4.3 SDK.
I have TARGETED_DEVICE_FAMILY defined at the target level and it looks like it is set correctly. The problem is the same for debug/release/...
have you selected the simulator as iphone?
most iphone apps are supposed to work on ipad too.
otherwise you may need to go to the project tab and go to project settings. there are some setting involving the choice of ios. i have not tried this since i havent recieved the error but i hope that it works.
Actually it turned out that I had Armv7 selected as architecture for my iPhone build. After changing that to armv6, I can now install and run the build on my device.

iTunes Connect: Excluding iPad From Supported Devices

I have just uploaded my first app to iTunes Connect and noticed that my list of supported devices is appearing as follows...
Device Requirements: Compatible with iPhone, iPod touch, and iPad.
I've developed specifically for the iPhone and iPod Touch and have not yet done any testing on the iPad simulator. I therefore don't want the app submission testers to try running my app on an iPad and rejecting it because of some minor issue.
I've looked at setting the required device capabilities in my info.plist, but that doesn't appear to allow me to restrict at a device level.
Is this a by-product of building using the 3.1.3 SDK? Are apps built using this SDK automatically upscaled to work on the iPad?
You can't restrict the app to not work on the iPad. Backwards compatibility with all iPhone apps is a feature of the iPad. Your app will run in a 100% frame or in an optional 2x mode depending on user preference.
iPhone OS apps that link against the 2.x or 3.x framework and test clean on the iPhone and iPod touch should work w/o any trouble on the iPad.
If you tested on the iPod, taking into account the lack of cell radio, camera, etc., you should be totally fine.
I don't see a good reason to exclude iPad since iPhone apps will run in emulated mode in iPad after all. It's the same situation as a 3.x firmware running apps compiled from 2.x SDK.
To restrict at device level, you add the UIDeviceFamily key, but this doesn't support excluding iPad (just excluding iPhone).
The way to indicate that an application should only run on iPhone is to specify your application as an iPhone type application, rather than universal. Open your project (in XCode), click on the project name at the top of the Project Navigator sidebar, select the target, go to the summary tab, and change "Devices" to iPhone.
When you submit it, it will only be run in emulator mode on iPads, thus getting around any issues.