thudugala/Plugin.LocalNotification

GeofencingClient was removed in Xamarin.GooglePlayServices.Location 121.x

ivmirx opened this issue · 3 comments

ivmirx commented

Describe the bug
Release builds with linker enabled fail with the following error:

/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Legacy.targets(5,5): Error XALNK7000: Mono.Linker.MarkException: Error processing method: 'System.Void Plugin.LocalNotification.Platforms.NotificationServiceImpl::.ctor()' in assembly: 'Plugin.LocalNotification.dll' ---> Mono.Cecil.ResolutionException: Failed to resolve Android.Gms.Location.GeofencingClient Android.Gms.Location.LocationServices::GetGeofencingClient(Android.Content.Context)

To Reproduce
Try building and running the app on device with Linker -> Link SDK assemblies only

Platform (please complete the following information):

  • Android, built with 13.0 target framework
  • Plugin.LocalNotification 10.1.8

Smartphone (please complete the following information):

  • Device: Samsung Galaxy A02 (SM-A022M)
  • Android 11

Additional context
Rolling back to Xamarin.GooglePlayServices.Location 120.x fixes the issue.

Not sure why the class is no there, doesn't seem like it's obsolete – could be a Xamarin package issue?

Anyway, thanks for the great plugin!

@ivmirx Can you please attach a sample project?

ivmirx commented

Sorry, I've been super overwhelmed lately and just can't setup a test project. Also the Xamarin packages for Android were just updated, so maybe it's fixed in a newer package version. I'll keep it closed for now if it doesn't happen to anyone else.

I have the same problem with my project.