Generating .ipa for a modular iOS project

Abhinav Mallick
2 min readMar 23, 2020

This article is written in context with Xcode 11.3.1

I was working on a project which involved multiple modules to be added as framework and I had to generate .ipa for the integrated app. I spent quite some time fiddling around with the different Xcode settings and finally I figured out the golden combination!

Steps to follow:
1. For the individual projects, for which you want to use the frameworks into your integrated app:
i. Click on the project
ii. Go to TARGETS -> Build Settings
iii. Search for Installation Directory and replace the existing /Library/Frameworks with @executable_path/../Frameworks/ no need to touch ‘@rpath’

iv. Build the project for Generic iOS Device

2. For the integrated iOS project:
i. Click on the project
ii. Go to TARGETS -> Build Settings
iii. Search for Enable Bitcode and set it to NO (in most of the cases you don’t need it and your frameworks were probably built without full bitcode)
iv. Now go to TARGETS -> General
v. Scroll down to ‘Frameworks, Libraries, and Embedded Content’ and make sure all of your module’s frameworks are there and for the Embed field set to Embed & Sign

Note: If you have other external frameworks like GoogleMaps.framework you don’t need to embed them into your project.

Also, before building the projects make sure that they are signed. Go to TARGETS -> Signing & Capabilities and tick ‘Automatically manage signing’

Now, just go to Product -> Archive and once archived, distribute your app in your preferred mode!

That’s all folks!

--

--