Packaging for iOS distribution FAIL

Hello,
I’m trying to package my game to IOS devices but I can’t figure out what I’m doing wrong.
I’m using unreal on a Mac, so I have Xcode installed, I’ve created my distribution certificate, uploaded to Xcode, added on KeyChain, and in Unreal.
I’ve also created my mobileProvision in Adhoc first to try to test the app on an iPhone device, but Unreal doesn’t recognize it as valid mobileProvision. Yes it has the same bundle name in apple developer and unreal. I tried everything I could to make it valid as put the same name as the unreal project, create the mobileProvision with “Distro_” prefix, and a lot of tests…

As you can see, I have three different certificates, two developer certificates and one for distribution. With the developer certificates I could import a valid mobileProvision and launch the game on my iPhone. I could also make a packaging .ipa but it didn’t work… When I tried to opened on my iPhone the app just shot down after the splash screen…

Finally, I also upload my log file when I try to import my mobileProvision, just in case anyone can use it to help me.
[Unreal Log][2]

Lastly I’m using unreal 4.15 engine.
I really don’t know how much I can do to make it work… I tried to create a basic Xcode project with my distribution certificate, make an .ipa file to Adhoc and it works perfectly…
If you need more info let me know! Thanks.

I have created a new blank project… And now all is valid…

But when I try to make a package or launch it on a device unreal tells me that there are no provisioning profiles or signing keys valid…

Is it really possible to make unreal work on iOS devices or is it just a myth?!

Updating info…
I have created a blank project in unreal engine 4.17.2 in a Mac mini. All the certificates and mobile provisions are ok. I tried it all with Xcode. Now I can make a develop and distribution packaging. The develop ipa works fine, the adhoc doesn’t… When opening the installed app shows the splash screen and closes…
here is the Xcode log…
link text

I’m so lost right now… I think I’ve had all the possible problems and errors unreal can give making an app for iOS…

Try this for ad-hoc provision applying.
You need to modify below codes of iPhonePackager Project in UE4 Source Version Engine(I’m using UE4.17.1).
It seems to be problem that ad-hoc provision must have devices but iPhonePackager code exclude ad-hoc provision that have devices for distribution.
I’m using ad-hoc provision by using modified codes.

[CodeSigning.cs]

  • Find below codes and remove ProvisionedDeviceIDs.Count check code like “bool bDistribution = !p.bDebug;”

“bool bDistribution = ((p.ProvisionedDeviceIDs.Count == 0) && !p.bDebug);”

  • Find below codes and remove bDistribution check code like “if ((string.IsNullOrWhiteSpace(SelectedProvision) || FoundName < 2) && Validity == “VALID”)”

“if ((string.IsNullOrWhiteSpace(SelectedProvision) || FoundName < 2) && Validity == “VALID” && !bDistribution)”

[MobileProvisionUtilities.cs]

  • Find below codes and remove ProvisionedDeviceIDs.Count check code like “bool bDistroProv = !TestProvision.bDebug;”

“bool bDistroProv = (TestProvision.ProvisionedDeviceIDs.Count == 0) && !TestProvision.bDebug;”