0

I have an ios app and its photo extension. I have certain dynamic frameworks that are required by both the main app and the extension. But I am struggling to make the dynamic frameworks available to both the main app and the shared app in a way that is acceptable for uploading the app to iTunes connect. The packaging structure of the final ipa of my app looks something like this:

MyApp.app/Frameworks – I copy all the required dynamic frameworks in this folder as part of copy files build phase

MyApp.app/Plugins/MyAppPhotoExtension.appex/ - Contains the executable for extension and other assets required by it.

I tried following approaches to make the required dynamic frameworks available for the extension:

  1. Create a folder MyApp.app/Plugins/MyAppPhotoExtension.appex/Frameworks and create symlinks here to the dynamic frameworks present in the main app at MyApp.app/Frameworks.

This works fine and the extension is able to find the frameworks during run time. But on uploading this ipa to iTunes, I get following errors:

ERROR ITMS-90035: "Invalid Signature. A sealed resource is missing or invalid

ERROR ITMS-90206: "Invalid Bundle. The bundle at 'MyApp.app/PlugIns/MyAppPhotoExtension.appex' contains disallowed file 'Frameworks'."

  1. Create a folder MyApp.app/Plugins/MyAppPhotoExtension.appex/Frameworks and copy the required dynamic frameworks here. So there are 2 copies of some dynamic frameworks inside the ipa. But now I get following errors on uploading the ipa to iTunes:

ERROR ITMS-90685: "CFBundleIdentifier Collision. There is more than one bundle with the CFBundleIdentifier value '[some value]' under the iOS application 'MyApp.app'."

ERROR ITMS-90205: "Invalid Bundle. The bundle at 'MyApp.app/PlugIns/MyAppPhotoExtension.appex' contains disallowed nested bundles."

ERROR ITMS-90206: "Invalid Bundle. The bundle at 'MyApp.app/PlugIns/MyAppPhotoExtension.appex' contains disallowed file 'Frameworks'."

Can anyone let me know what is the right way to share dynamic frameworks between main app and its extension? The extension should be able to find the required dynamic frameworks at run time. Has anyone done this before and got the app successfully uploaded to iTunes?

Rahul
  • 51
  • 4

1 Answers1

0

If you want to use same framework in your app and extension, you should create a new target in your Podfile and pod your framework there.. in the same podfile of your project

 target 'Name Of Your Extension' do
         pod  'Alamofire'
 end
MAGiGO
  • 599
  • 5
  • 13