Hi! I’m an iOS developer, but I’m new to Defold and I really enjoy working with it so far. I’m having some trouble creating a development build to test on my device, though. No matter what I seem to try, my app crashes as soon as I launch it.
The device logs show the same thing every time, no matter how I’ve built the app/what provisioning profile I’m using: Crash Logs Gist
I’m using the latest Defold/macOS/iOS/Xcode versions and tried a provisioning profile created on the Apple Developer site as well as pulling one from inside a clean Xcode app build as detailed in the Defold manual. I made sure to set the correct bundle identifier in game.project. I’m installing the built .ipa file from …/build/armv7-darwin via Xcode > Devices & Simulators. I even wiped my drive and reinstalled macOS to make sure there wasn’t a strange certificate/profile mismatch error, but I haven’t had any luck unfortunately
I really hope someone can give me some pointers, because I’d love to be able to use Defold for a new app!
Failed to parse entitlements: AMFIUnserializeXML: duplicate dictionary key near line 12
Are you using custom entitlements for your app (using the ios.entitlements key in game.project)?
According to this code, Defold tries to merge the entitlements in your provisioning profile with the custom ones that you specify unless you also set ios.override_entitlements to 1.
Otherwise, check the entitlements in your provisioning profile. Maybe they actually are corrupt or something.
Thanks for your reply! I’m not using any custom entitlements; I’m actually just trying to run the default mobile project from Defold that I created from New Project > Mobile game. The only thing I changed in game.project was my bundle identifier.
I compared my downloaded provisioning profile with the embedded.mobileprovision inside the ipa archive bundle, and they don’t appear to differ.
I’ve deleted and created several provisioning profiles from the Apple Developer site at this point, so I wouldn’t think every one of them would be corrupt… The only capabilities I have enabled are the default ones – In-App Purchases and Game Center.
Ok, I’ve checked my provisioning and found that I have only one element in keychain-access-groups, but I use old provisioning profile (I created it for a long time ago).
@AGulev Interesting! I confirmed that my provisioning profile has those same entries in it. Does this mean any iOS build created with a new provisioning profile won’t run? If so, I’m relieved it’s not my environment at least, but not sure where to go from here…
@astrochili Have you had any luck getting an iOS build to run?
@astrochili Thank you! I was able to get the build to run on my device using that technique. Have you submitted any production builds to Apple using this method yet, and if so, does anything need to change when using an App Store Distribution vs Development profile?
@AGulev Thank you for creating the issue and for your help with this! I’m glad the build is working, even if it’s just a workaround for now.