iOS Build Error

Hello, all. 

I’m having problem with building for iOS with the version 2019.3517. I tried to build and copy to the device a few times but I was not successful. Then I tried to build and upload to the AppStore, I had errors again. Then I tried to build and open with a simulator, had no success. 

Logs from the last try: https://pastebin.com/P2QymiDR

By the way, builds take more than 10 minutes. Is it normal? I have very fast internet. 

Are you trying to build for iOS Simulator? Looks like the Facebook Audience network library does not have the i386 bits. Build and deploy to device and it should work or remove the FAN plugin from the list of plugin for the iOS Simulator.

@agramonte, the logs are from the build for iOS Simulator. Before that I tried to build and deploy to a device, build and upload to App Store but none worked. 

I suspect the other error would be different. Can you post those? The error you posted is specific to FAN plugin not having i386 portion for iOS Simulator.

@agramonte, I commented out the FAN plugin and was able to build. But this time I got error on startup on both device and simulator. I think the problem was related to the problem on this link: https://forums.coronalabs.com/topic/76047-ios-appodeal-fails-to-build/

I added the plugin.notification plugin and built it. Now it works. I will enable the FAN plugin and build again to see if it works with that one. I’ll do that tomorrow as it’s late and I don’t want to wait for half an hour more. By the way, does your mac also take half an hour for a build to finish?

Yes if it finishes. Problems downloading plugins usually. It might be my fiber connection to the internet. 0_o

I was successful to build and copy to device. It’s ok now but this time I want to build and copy to Simulator in order to take screenshots. I tried two times without having success. I also tried uploading to App Store, it keeps giving me this message: “Only apps built with distribution profiles can be sent to the App Store. Choose a provisioning profile signed with an “iPhone Distribution” certificate and note that the provisioning profile used should not specify any devices (i.e. is not “ad hoc”).” However, I have already downloaded the distribution profile. I deleted all the provisioning files and downloaded and installed again. I still get the same error. 

Anyone knows how to solve the problem?  :wacko:

Are you copying the profile to your ~/Library/MobileDevice/Provisioning Profiles/ folder and restarting Corona?

Does Corona present you with the distribution profile to use?

Keep in mind Apple has three types of profiles:

Developer

Distribution (AdHoc)

Distribution (Store)

In their interface, they only show two and when you go into the Distribution one, you can pick for the store or AdHoc, but if you don’t name your profile indicating that it’s AdHoc or Store, there is no way to know because it will just say distribution. I always make sure to explicitly name my profiles:

My Awesome Game (Developer)

My Awesome Game (AdHoc)

My Awesome Game (Store)

that way there is no ambiguity on which distribution profile is which.

Now some people will let Xcode manage the download and storage of the profiles. But when you do, you end up with filenames like:

f3e44b5f-c6d9-41e4-9f14-7d0cf6dee834.mobileprovision

Where as if you, from the developer portal choose “Download”, you get names like:

Alien\_Invasion\_AdHoc.mobileprovision Alien\_Invasion\_iOS\_Distribution.mobileprovision

But you have to be a little command line friendly or know how to use finder to get to ~/Library since Apple tries really hard to hide that folder from Finder. The command line is quite easy to do for this. Download your profiles using the Download folder. They **should** end up in your ~/Downloads folder unless you’ve told your browser to do something else. I’m assuming you’ve not changed this.

Open the Terminal (click on the Spotlight magnifying glass and type “terminal” and hit enter. In the window that opens, type:

cd ~/Library/MobileDevice/Provisioning\ Profiles mv ~/Downloads/\*.mobileprovision . ls -l

This will take you the right folder, move the files you downloaded from Downloads to the right place

and then the ls -l will give you a list of the files that are there.

Close the terminal, restart Corona and all your current profiles should be available to choose. If you named them appropriately you should be able to see them in the directory list and with the more human readable name you used in the developer profile.

Make sure you pick a “For the Store” profile and you should be good to go.

Rob

Rob, thanks a lot for a long reply and help. 

I tried deleting everything in ~/Library/MobileDevice/Provisioning Profiles/ folder and downloading from Developer Console. I have never created Ad Hoc profile but Developer and Distribution profiles. Moreover, I name the profiles as you mentioned in order to prevent confusion. 

I keep downloaded profiles under the folder named “Mobile Provisions”. I tried to delete and install profiles again while writing this reply. Then I restarted Corona, chose the Distribution profile for the build and chose “Send to App Store” option. This time it gives me this:

Corona Simulator wants to access key “Application Loader” in your keychain. To allow this, enter the “login” keychain password.

When I write my password for Mac, it gives me the same “ad hoc” related error.

A few days ago after being unsuccessful to build and upload to App Store, I tried to use Application Loader but I noticed that it asks me to sign in. It was normal as I had to format my Mac after upgrading to Mac OS Beta version.

After logging in to Apple Developer portal it asked me to generate a one-time password for the Application Loader. I did so, downloaded and installed it. 

iOS SDK version is 12.4 

Can you copy/pasted exact messages you’re getting. We would also like to see screen shots of all of these steps. I can’t see your developer portal where you’ve created  the profiles. You can copy/paste or screen shot your ~/Library/MobileDevice/Provisioning Profiles/ folder. Screen shots of where it’s asking for your password and the error you get from it.

You can add screen shots by clicking the “More Reply Options” button beside the “Post” button and it will let you attach images.

Rob

Rob, the screen shots are attached to the post. I tried a few times but could not produce the password asking screen again. I deleted all the profiles from the ~/Library/MobileDevice/Provisioning Profiles/ folder and then added again by clicking on the downloaded profile files. I even created a new app and new provisioning profiles so that it might ask the password again. 

By the way, I tried to use Application Loader to upload to the App Store but I can not select the iOS build from the folder. Is it possible that it is related to the problem?

Can you open up the profile to see the details and provide a screenshot similar to:

Rob

Rob, it is the screen shot for me. 

Rob, I created a new Identifier, then created Profiles for Development and Distribution, then downloaded and installed them. Then I tried to build the app and to choose “Send to App Store”, I got the password asking screen again. I am attaching the screen. When I type the password I use to login to Apple Developer website, the login screen shakes which means the password is not correct. The same thing happens when I use the one-time password I generated for Application Loader. However, when I use my password for the Mac login, it shows me the “Only apps built with distribution profiles can be sent to the App Store” message. 

Are you checking “Always Allow” when you enter the password?

With the last one, I did not but the previous ones I used “Always Allow” option too. 

Just out of curiosity have you launched and run Xcode since the last time it was updated?

Rob, when I click on the downloaded provisioning files, it opens Xcode, so, I think, that should be considered “yes” for your question.