google-maps-ios-utils icon indicating copy to clipboard operation
google-maps-ios-utils copied to clipboard

Package Maps SDK for iOS in .xcframework to ease SPM integration

Open arriolac opened this issue 5 years ago • 47 comments

Comment or +1 this issue if this is something you'd like to see in the library so it can be prioritized. Also a good candidate for contributions.

Is your feature request related to a problem? Please describe. Currently, integrating this library with SPM requires that developers additionally include Maps SDK for iOS either via CocoaPods or Carthage. In other words, the Maps SDK is not packaged in the .xcframework which causes additional friction and confusion (see #326) while using this library.

Describe the solution you'd like The Maps SDK for iOS should be included in the .xcframework.zip asset on each release so that developers can just include the iOS Utils library.

Describe alternatives you've considered Keep existing integration.

Additional context See #326

arriolac avatar Aug 13 '20 00:08 arriolac

As the confused in #326 I'm a proponent. Without it being included I have to maintain Google Maps manually or use Carthage, both of which require a lot of extra steps I'd rather not mess with again. Cocoapods is not an option for my team. Additionally I think it'd be a great idea for google-maps-ios-utils to maintain the proper Google Maps version. If there is an version incompatibility down the road, it'd be on the developer to figure out the issue and update either this or Google Maps to the appropriate version.

michael-mckenna avatar Aug 13 '20 00:08 michael-mckenna

@michael-mckenna curious... why is CocoaPods not an option for your team?

arriolac avatar Aug 20 '20 17:08 arriolac

Mainly two reasons. The primary is that we are transitioning to SwiftPM as it's the officially supported dependency manager. The second is that cocoapods lead to dreadfully slow incremental build times which slowed the development cycle. Switching to Carthage remediated that issue, so there's no looking back for us ;) if memory serves me correctly, we got our incremental build times down from 1m45s on cocoapods to 23s with Carthage. This was also 2-3 years ago.

michael-mckenna avatar Aug 20 '20 17:08 michael-mckenna

Wow, that's quite a huge difference 😅 Thanks for providing context.

arriolac avatar Aug 20 '20 18:08 arriolac

@arriolac Will this integration allow building for macOS catalyst? somewhat relevant. Right now, I can't build for catalyst form the frameworks in the google maps zip

michael-mckenna avatar Aug 23 '20 00:08 michael-mckenna

@michael-mckenna the built XCFramework simply mirrors the architectures that are currently supported by the SDK (arm64 & armv7 for iPhones, and i386 & x86_6 for Simulators). Adding support for Mac Catalyst, which we are evaluating and will eventually support, would be a separate step.

arriolac avatar Aug 24 '20 18:08 arriolac

+1 for a solution that would allow using only the officially supported dependency manager.

luispadron avatar Nov 09 '20 19:11 luispadron

@michael-mckenna the built XCFramework simply mirrors the architectures that are currently supported by the SDK (arm64 & armv7 for iPhones, and i386 & x86_6 for Simulators). Adding support for Mac Catalyst, which we are evaluating and will eventually support, would be a separate step.

Don't forget add arm64 for Simulators, so we can use it on new arm macs 😉

Scvairy avatar Nov 19 '20 09:11 Scvairy

This is marked as good first issue, but it’s really up to the maintainers and distributors of https://cocoapods.org/pods/GoogleMaps. There is a lot of good information on xcframeworks here: https://github.com/bielikb/xcframeworks. It’s likely a simplification of the existing process for packaging the GoogleMaps framework and wouldn’t take much effort for someone to repackage it.

It is probably possible that someone external to google could download the existing release and repackage it as an xcframework, but I doubt Google wants the officially supported way to use google maps for spm and m1 macs to be: download a modified version of our binaries from someone else...

cltnschlosser avatar Jan 31 '21 19:01 cltnschlosser

I filed this issue considering that the existing Maps SDK for iOS .framework could be packaged into the Maps SDK for iOS Utility library .xcframework. However, that's not really how SPM packages work.

Rather, the steps to mark this issue fixed would be: (1) for the Maps SDK for iOS to support .xcframeworks, and (2) update Package.swift for this repo and specify Maps SDK for iOS as a dependency. (1) needs to be done by us, and (2) can be done by us or a contributor. Since this issue is blocked by (1), I'll remove the good first issue label since you are correct that this needs to be provided by us.

(1) currently has no ETA so if you are using .xcframework version of this library you will need to include the Maps SDK for iOS dependency in addition using one of the installation options (CocoaPods, Carthage, or manual).

arriolac avatar Feb 01 '21 17:02 arriolac

Big +1 to this issue. I'd love to see GoogleMaps properly available via SPM. It's the primary blocker in moving my large app fully onto SPM now.

mthole avatar Apr 07 '21 16:04 mthole

Any update on this issue? It’s a blocker for a lot of users.

luispadron avatar Apr 13 '21 04:04 luispadron

Please see my comment here https://github.com/googlemaps/maps-sdk-for-ios-samples/issues/70#issuecomment-811231129

arriolac avatar Apr 13 '21 17:04 arriolac

Any update on this feature request?

SaidAlSouti avatar Jun 03 '21 13:06 SaidAlSouti

+1, still waiting . xcframework

iserbius avatar Jun 07 '21 12:06 iserbius

+1

federicopolesello avatar Jun 16 '21 08:06 federicopolesello

+1

RyuX51 avatar Jun 24 '21 11:06 RyuX51

+1

steffenbirkis avatar Jun 28 '21 10:06 steffenbirkis

+1

piotrekjeremicz avatar Jul 01 '21 13:07 piotrekjeremicz

+1

twprzybysz avatar Jul 15 '21 16:07 twprzybysz

+1

After the release of the SPM-compatible GoogleSignIn SDK this week, the Google Maps SDK is the last one for us that does not yet support SPM. So this would be highly appreciated🤞

mathaeus avatar Jul 16 '21 12:07 mathaeus

@arriolac Hi! Could you please clarify, since new 6.0.0 version of Google Maps SDK is available and #355 is closed, may we use this new XCFramework version in our local Swift Packages?

thehavre avatar Dec 03 '21 10:12 thehavre

+1

ElysiumWhale avatar Dec 03 '21 10:12 ElysiumWhale

+1

thr1llseek3r avatar Dec 03 '21 10:12 thr1llseek3r

+1

EastHell avatar Dec 03 '21 10:12 EastHell

+1

Vl330 avatar Dec 03 '21 11:12 Vl330

+1

petropavel13 avatar Dec 03 '21 11:12 petropavel13

+1

akhakimzyanov avatar Dec 13 '21 09:12 akhakimzyanov

+1

Neilfau avatar Dec 17 '21 08:12 Neilfau

+1

VincentDurandChewbi avatar Jan 06 '22 15:01 VincentDurandChewbi