Cannot debug iOS project on device - ios

Weird error is occurring to me, I followed the guide from apple, to provisioning portal to test the project on a real device, create a certificate, add a device an appID and then the provision file.
Edited all the code signing identity settings to the new iphone developer provision file, and tried to run on my device.
The base of my SDK is 4.2,my device is 4.2 as well, but when i click the run button, its compile all the files, give me the build succeded message but even install on my device, its like none device was connected....

If your device is appearing here:(In the place of "iPhone 5.0 Simulator") Then your device is correctly connected.
And if your device says "Finished Running" When it hasn't even started running then as 'AlexeyVMP' said there are a few more steps to get your app to run on an ARMV6 device (usually the only reason anyone is still on iOS 4.2 these days)
Basically you have to add armv6 to the architectures in the project pane and remove armv7 from the required devices capabilities in the info.plist of your project.
You can see screenshots of these steps at this stackoverflow question in my answer.

Related

Xamarin Deploying iOS App Ad Hoc Failing to Install

I am trying to deploy an iOS app Ad Hoc to an iPhone for beta testing. I've been developing the app on Windows VS, I have a Macbook air with all the necessary software (Xcode, VS, etc), and I have paired to it with VS on my Windows machine. I have also followed the following steps:
Created an Apple Developer account
Created an App ID with the bundle identifier as the same exact one as the one in info.plist
Created a signing certificate using my Macbook Air, downloaded it, and installed it into XCode
Created a provisioning profile with the App ID and the certificate, and made sure to include the device that I want to load the app onto.
Made sure everything above was set to "distribution" and "ad hoc" as needed.
Set Bundle Signing in my iOS project properties to Manual Provisioning, and selected the Signing Identity and Provisioning Profile to the ones that I created for this deployment.
Set the build to Release and the target to Remote Device
Ensured that the deployment target in info.plist was set to the highest available, which is 15.4, though my iPhone is at 15.6 (could this be the problem?)
Set the IPA Packaging Options to "Build iTunes Package Archive (IPA)"
Set "Include iTunesArtwork images and the iTunesMetadata.plist" to true in the same area
Successfully built the iOS project and produced a .ipa file
After all that, I've been trying to get the .ipa onto my phone, which is definitely the device I added to the provisioning profile.
I've tried two methods to do this, and both have failed:
Connecting my phone to my Windows machine and opening iTunes. Dragging the .ipa file onto the device. The app shows up on my phone, but when I try to open it, I get this error:
"This app could not be installed because its integrity could not be verified". Though it should have been.. The device is linked to the provisioning profile that was used to create the darn thing.
Connected my phone to my Macbook Air and accessed the device through XCode > Window > Devices and Simulators. I emailed myself the .ipa file and downloaded it onto the machine (the Microsoft docs explicitly state that emailing the .ipa should work just fine). In the "Intalled apps" section of the device, I clicked the little '+' and then pointed it to the downloaded .ipa. After a few seconds, it pops up an alert window that says "Unable to install *.iOS".
Other things I have tried since this has been a problem:
Recreating the above steps by re-registering my device, creating new certificates, downloading, installing, all that business.
Messing with the deployment target version.
Jumping out from behind the couch and startling it to make it do what it's supposed to.
I swear I'm done with Xamarin forever after this problem is solved, but all the headaches I've experienced have made me think twice about whether to even bother with .NET Maui haha thanks for any help you can provide
Firstly, the error This app could not be installed because its integrity could not be verified" may be caused by the proper certificate or the test devices are not visible in 'Devices' (UDIDs added) in developer.apple.com/account.I found two simialr issues, you can refer to them: link1, link2.
Secondly, have you follow this docs on how to generate the IPA file?

Error trying to copy IPA from Xcode Devices&Simulators to device

I created one IPA via Xcode.
Product -> Archieve -> Distribute Ad Hoc for target real devices any ios armv7, arm64
(so far process was same as always and had it working before with iphone)
The only thing that is changed is that I am using one IPAD instead of old Iphone (sold)
I have registered the IPAD already under my devices at https://developer.apple.com/account/resources/devices/list
Then I deleted old Xcode provisioning profiles following the instructions here
by going to ~/Library/MobileDevice/Provisioning and deleting all. Then I saw Xcode "fixing" recreating with todays date the new profiles.
Still issue persist, when I drag and drop IPA to device I get error "Unable to install AppName"
The error message is very short and does not give any detailed information of possible causes.
More details:
Info.plist
<key>MinimumOSVersion</key>
<string>9.0</string>
IPAD is already >= 9.0 version as well
The host device that I used to create the IPA has arm64 architecture, macbook m1 2021
How can I fix this and manage to install the IPA into my ipad and real test the app ?

Install app on iOS device (iPhone / iPad) or create .ipa from Xcode without code signing and developer account

I am new to iOS development and self learning. I have created couple of apps and already tested in iOS simulator. These apps runs perfectly fine without any issues and warnings pre or post build.
I wanted to run apps on my iPhone for realtime testing. But cannot extract .ipa package from Xcode as i did not subscribe to developer's account yet (will do later). Tried few tweaks and followed below steps :-
Updated SDKsettings.plist and set CODE_SIGNING_REQUIRED, ENTITLEMENTS_REQUIRED to value NO.(read at tech blog)
Created archive and export method as : "Save for Ad Hoc Deployment"
Further steps asked for developers account again. So tried to fetch .app /.ipa from xcarchive in two ways :
a). Run command line:
xcodebuild -exportArchive -exportFormat ipa -archivePath /Users/../Library/Developer/Xcode/Archives/..\app.xcarchive/ -exportPath /Users/../Desktop/app.ipa
b). Copied .app file underneath the above xcarchive package. Dargged and dropped to iTunes "MyApps"
Within iTunes, i noticed that app size grew from 2.2 MB to 8.4 MB.
Connected iPhone using USB and performed install then clicked sync/apply. App gets installed on device but iTunes shows "installing"
Disconnected USB, installed App has no icon image. When touched to open the app, it starts installing and never opens up.
Please help suggest pointers so that i can test my app without developer's account.
Please try to download the beta version of XCode 7, so you can do this in an "official" way. Or you can wait until XCode 7 is released to the public.
When I was starting at development and I didnt have an Apple Developer Membership I used JailCoder. With this tool you can fake sign your apps and install it into your device wothout a membership, and most important, DEBUG your apps. You need a jailbroken device

Apple Watch, Failed to install XXX, error: Application Verification Failed

We submitted an app recently with Apple Watch support. It installed from the App store fine but when preparing an update, we can't get it to install on a real Apple Watch anymore (fine in simulator). We have tried installing using Apple Testflight Beta and Ad Hoc builds (we, the developers do not have an actual device ourselves, just a remote tester).
The only significant thing that has changed is that we have updated to XCode 6.3 since the first release.
I have tried:
Adding/removing beta-reports-active: Debug on real Apple Watch: Application Verification Failed
Verified that the deployment target is iOS 8.2.
UUID for watch and phone are in the provisioning profiles
Provisioning seems OK when examining IPA bundle and it can be uploaded to Apple Testflight
Rebooting XCode, machine, etc.
The one thing that is suspicious, is that when exporting the IPA from XCode, the entitlements summary for the watch app have a circle/cross for the icon (no error is reported though). Also, the keychain-access-groups value is by default set to the Watch app's bundle id (not the host app). I have tried creating my own entitlement file to match though, and this doesn't seem to do anything. I would attach a screenshot but I don't have a 10 reputation...
Any help with this would be great. It is very hard debugging when you don't have the actual device. I have to make builds and wait for the one remote tester to try. Then repeat...
Update:
Now that I have the rep, here is the screenshot:
I did get a watch. The first time I tried to install it, it gave the same error. I then tried debugging in Xcode. It would install through Xcode (Xcode created provisioning XC profiles). Subsequently, I could get it to install using Testflight Beta. However, it still would not install for our external tester!
Check your certificate entitlements. Go to apple developer center and accept the new entitlement if any. Make sure you are not using beta Xcode to publish the app.
Try validating the build before pushing to Test flight(validate in archive area) and also do check the certificate is a distribution certificate.

Test iPhone app in real device

I have an apple developer ID. I have my developer certificate, my cert in my keychain, I have installed the last version of iOS (5.1.1 (9B206)) in my device (an iPad), I got my profile, I'm on a development team, I told Xcode that I want to use the device for testing. In the build settings, I have set the architectures to armv6 and armv7, both in "target" and "project" as well. Got the provisioning profile.
Still, when I try to run the app on the iPad, I receive an "Xcode cannot run using the selected device." saying that I need to install a newer iOS version (as I said, I installed the most recent on the device).
Anyone have faced this issue before?
You will need to update the version of Xcode to 4.3.2

Resources