FirebaseUI-iOS icon indicating copy to clipboard operation
FirebaseUI-iOS copied to clipboard

Distribution as an XCFramework

Open vadimbelyaev opened this issue 3 years ago • 3 comments

When building for Apple platforms, Firebase provides a way to include it into the project without a package manager using an XCFramework. It vastly improves build times, especially in CI environments where incremental builds aren't happening (saving about 30 minutes of build times).

However, FirebaseUI isn't currently getting distributed as an XCFramework and I'd love to see it happen some day.

Cheers! -Vadim

vadimbelyaev avatar Jul 22 '22 20:07 vadimbelyaev

We don't have a good method of synchronizing FirebaseUI binary releases with Firebase upstream binary releases since they're both on different release schedules. However, you could manually include FirebaseUI as source via git submodule (though this requires manually keeping the versions in sync) and use Firebase via the XCFramework approach you described. Most of the build time savings will come from Firebase itself, since FirebaseUI is a relatively small codebase (less than 1% the size of Firestore alone, including Firestore's dependencies).

morganchen12 avatar Jul 28 '22 20:07 morganchen12

@morganchen12, thanks a lot for your response and sorry for my delayed reply.

I tried adding FirebaseUI as a git submodule while having Firebase as an XCFramework, but my attempts were not successful, mostly because of transient dependencies that are the same for FirebaseUI and Firebase iOS SDK. I think mostly it's just my lack of experience in setting up the build configuration in such a way.

I'm okay with closing this issue since I understand the fundamental constraints that you describe.

If someone from the community knows if there is any documentation or tutorial available on how to configure the project to use Firebase as an XCFramework and have FirebaseUI as a git submodule, I'd love to read it. Until then, looks like I'm destined to just use SwiftPM :)

Cheers and thanks for the great work! -Vadim

vadimbelyaev avatar Sep 15 '22 22:09 vadimbelyaev

I'll leave this issue open, since it's a significant increase in complexity to include a dependency via submodule instead of prebuilt XCFramework.

morganchen12 avatar Sep 23 '22 21:09 morganchen12