Can't create ipa from Xcode 7 - ios

My project was initially build with the early version of Xcode.
Even with Xcode 6 I was able to export the app (Ad Hoc, ipa file).
After that we started to use continuous integration & upload of builds to iTunes.
Also, I have deleted my working copy.
Recently, I have to make fixes in the project.I checked out the source code, updated my Xcode to the latest version - Xcode 7, updated the project.
But now when I am archiving the app, it goes under unknown app in Organizer, I can't create ipa ( Validate button is not active).
For some reasons the app, in the Organizer doesn't have a valid identifier
I tried to use a new
PRODUCT_BUNDLE_IDENTIFIER
and directly to set correct bundle ID, but I still have 2 items, instead of one app.

In build setting under build option Disable bitcode.
In build setting under deployment set false to skip install.

Related

Xcode showing distribute content instead of distribute App. Xcode 13.2.1

I recently updated to Xcode 13.2.1, I want to release an app to the app store but when I do Product => Archive, it shows Distribute Content instead of Distribute App. I checked my build settings, it has skip install to No. Any idea how to fix it.
Here is the screenshot of the build settings.

Unable to update existing app store app [duplicate]

Previously with Xcode 7.3.1 I was able to build directly over my app store app on my iPad and test the upgrade scenario, which worked perfectly fine. This week I upgraded to Xcode 8 and when I try the exact same approach, I keep getting this upgrade error
"This application's application-identifier entitlement does not match that of the installed application. These values must match for an upgrade to be allowed."
I tried multiple solutions posted on this thread and none of them worked. I also don't have a watch app. Just a simple iOS app target.
App installation failed due to application-identifier entitlement
I deleted my certs and provisioning profiles and recreated them and still the same problem. I then went and downloaded Xcode 7.3.1 and tried it again with the exact same problem.
Now I am stuck without being able to fully test my upgrade scenario.
PLEASE HELP !!
I had the same issue while trying to upgrade application.
And here what I've found:
I checked application-identifier entitlements of old app and new app. You can do that by running codesign -d --entitlements :- path/to/AppName.app/AppName or open file "archived-expanded-entitlements.xcent" at path "AppName.app/AppName".
Application-identifier of old app was "1234XXX5X6.com.mycompany.myapp" but in new app it was "1234XXX5X6.com.mycompany.myapp.develop".
Usually I set "Bundle Identifier" directly in Info.plist.
But I didn't know that there is also a "Product Bundle Identifier" property in project Build Settings.
The previous version of app was built with Xcode 7.3.1 and it had following settings:
Info.plist: com.mycompany.myapp
Build Settings: com.mycompany.myapp.develop
application-identifier: 1234XXX5X6.com.mycompany.myapp
The new version was built with Xcode 8.2.1 and it had following settings:
Info.plist: com.mycompany.myapp
Build Settings: com.mycompany.myapp.develop
application-identifier: 1234XXX5X6.com.mycompany.myapp.develop
Seems like new Xcode have different source for application-identifier.
So I just corrected "Product Bundle Identifier" and my problem was solved.
Remove the existing application from the device and Run again.
To fix this just enable "Automatic manage signing" from general tab of project settings.
I had also problem for running app on my device directly from xcode 8. Deleting and generation profile and certificate did not worked for me. But enabling "Automatic manage signing" worked for me.
Hope this helps!
Check this question of mine:
Xcode 8 shows error that provisioning profile doesn't include signing certificate
Here is one solution if you want to upgrade over your existing App Store app without deleting it but your application-identifier entitlement does not match. Upload an archive of your new build to the App Store and then use TestFlight to download it to your device. This is not as quick as building to the device, but it will overwrite your old app with your new build while keeping your old data in place. For (relatively) quicker turn-around testing of your upgrade process once you have a new build available on TestFlight:
Delete your app off of your device (assuming it was a recent build)
Download your app store build and generate some data
Download your TestFlight build, but don't run it
Build your newest build directly to the device
The TestFlight build overwrites the entitlement without deleting the old data, so Xcode happily will install your new build over the TestFlight build, but you are still testing your upgrade process as if you were building directly on top of the App Store version of your app.
I got this from an .ipa generated as a Jenkins artefact. The problem for me was that Jenkins was using a different provisioning profile.
I manually set Jenkins to use the same profile as the updated version that I was trying to install, and it started working.
Select the App Target and click on General, if you select or ticked checkbox automatically manage signing.
Untick this automatically manage signing and select appropriate signing provisioning profile and #Build and run again.
See the below photo.
Solved!! Short answer - delete old app from your iPhone
I went to my iPhone storage and used the search bar to find the offending app(because it wasn’t showing on the app list) and found an old version hidden, deleted it and now it works.
What worked for me was to go (within Xcode) to Window > Devices and Simulators, then select my iOS device and delete the app there. This is detailed in this Medium article.

IPA Wrong version number in archive

I changed the version for my app in Xcode's "General" settings to be 0.3.0. I saved it and also looked into Info.plist, the version was also updated there. But when I archived it and looked for the version number in the generated .ipa file, I found it to be the version of the last archive I made for this project (which was 0.2.0). Thus I cannot upload the archive via Application Loader because the build with this version already exists in my iTunesConnect. How can I get Xcode to archive with the correct version number?
In my case I'd update it in "General" but the Info.plist file for release builds hadn't also been updated. Updating it manually there fixed the issue. The "General" tab numbers weren't used at all.
Remove device if your device connected with mac and build archive with generic device.

Xcode 7.3 Upload to iTunesConnect (TestFlight build) failed

Previously we submitted an app using Xcode 7.3 but now it always fail with "iTunes store operation failed" error with Xcode 7.3 for the past 10 days.
we made a build with Xcode 7.3 and uploaded by using Application loader 3.0 got "Missing Beta entitlement" and the build was not available for testing.
I had a similar problem too, it seems that Xcode 7 build can only be sent by using the application loader of Xcode 8.
My suggestion is to build your app using xcode 7 export it as App Store build and upload using application loader but of Xcode 8.
The application loader is inside Xcode menu->Open Developer Tool
It Will occur due to following reasons
1. I think you are using development or distribution certificates instead of app store certificates
2. Check once in your project folder target->capabilities->associated domains must be off before submitting app to app store
3. Did you add application new version in iTunes store
Please change the build Version then try to upload it. Make sure before building or archiving clean the project.
First Thing
Here are the basic steps to upload the app form Application loader:
1.Archive
2.Export
3.Xcode menu --> Xcode --> Open Developer Tool --> Application Loader
4.Double click "Deliver Your App" and choose the file exported in step #2
5.click next and follow the instructions until the end
Second Thing
1.Set team in target-> General-> Team
2.Check and set appropriate provisioning profile in targets/project build settings.
3.Try with Xcode to upload build if find same issue. Or
4.Try with application loader it will work.
If it is still not working then just upload the ipa with Application Loader 2.9.1.
Download Application Loader 2.9.1 or here

Xcode 6 archive for AdHoc distribution

I have to distribute an app via AdHoc distribution. With Xcode 5 after the archiving, I select the option "Save for enterprise distribution" and then insert the web url where I upload the .ipa and the .plist.
Now in Xcode 6 this option is disappeared and I can't able to generate .ipa and .plist, but only the .ipa.
There is someone that know how to create .ipa and .plist in Xcode 6 for upload this files on a web site to allow an easy way for tester to install the app on iOS7 where testglight doesn't run?
Solution 1):
Download Xcode 5.1.1. and install it separately from Xcode 6.1. (in a different folder).
This way you can generate .plist files easily since you mentioned that you need it for iOS 7.
You can always keep Xcode 5.1.1. around and open your current project from it.
Solution 2):
Use your old .plist files or create a new one :
Xcode 6 Save for Enterprise Deployment does not create plist for ipa anymore?
Solution 3):
Wait for apple to fix this "bug" in the upcoming Xcode versions :).
If you have a plist from previous exports, you can use the same one. I distribute an app using enterprise deployments and all I do is create the ipa and upload it to the server. I created my plist file quite some time ago. You can also update the data in there if you need to, but so far I have not run into any issues with pushing a new version with out updating that file.
When you press export you get 3 options one of them is save for enterprise deployment.
But you can use testflight instead and save the app for adhoc deployment.

Resources