views:

83

answers:

1

I want to run my iPhone app in debug mode on my device. I have a valid certificate and provisioning profiles for developer and debug. I also have my code signing identity set to "iPhone Developer" in my project preferences. However when I try to install my app, it asks me if I want to install the ad hoc distribution profile. This is strange because I explicitly tell it to use the iPhone Developer code signing identity. Using the ad hoc distribution profile won't work because it doesn't have debug rights.

Anyone know how to fix this?

A: 

Hi, Tony! Maybe it can help you: Go to Project -> Edit Project Settings -> Build

In "Configuration" dropdown list select Debug configuration (not "Active") and then check you build settings. Entilements.plist should not be added to debug configuration.

Try to do so. Sometimes Xcode ignores the settings for the active configuration and uses the previous configuration.


Check info.plist file, that you use for debug build (it can be setted in build configuration with "Info.plist file" key). I think, "Bundle Identifier" in this file is equal to App Identifier in your AdHoc profile.

logovazz
I thought you needed entitlements to put an app on your iphone. Now I get the error "A valid provisioning profile for this executable was not found." even though my development profile is on my phone
Tony
If I delete all provisioning profiles on my phone, set the environment to debug on device, it still asks if I want to install the ad hoc profile. Not quite sure why it wants to associate the ad hoc profile with my debug configuration
Tony
i'm edited my answer, check it!for debug build bundle identifier in plist file must be equal to app name in debug provision profile
logovazz