Closed PawKanarek closed 4 years ago
It turn out that i need to install Xamarin.GooglePlayServices.Location nuget package... Can you add this package as nuget Dependency to your Com.Onesignal nuget package? Also, that's ultra wired that i need to install some .jars into project to run Com.OneSignal...
@PawKanarek You could add -dontwarn com.google.android.gms.location.** to your r8 / d8 config. It isn't in the consumer-proguard-rules.pro file as it is included as an automatic dependency for the native SDK, but not for this Xamarin SDK.
So maybe you could add nuget Xamarin.GooglePlayServices https://www.nuget.org/packages/Xamarin.GooglePlayServices.Location/ as dependency to com.onesignal nuget?
Howdy, Apologies for the delayed response. Are you still encountering the issue or can I go ahead and close?
Description
New project configured to run with D8 and multi-dex with package Com.Onesignal won't compile because: 2>R8 : warning : Missing class: com.google.android.gms.location.LocationListener 2>R8 : error : Compilation can't be completed because some library classes are missing.
Steps to Reproduce Issue:
Output:
Additional info
When mulidex is disabled, everything runs well (but my original project is huge, and wont compile without multi dex)
Environment Runing on Android 9.0, Huawei Mate 10 Pro Microsoft Visual Studio Professional 2019 Version 16.4.6 VisualStudio.16.Release/16.4.6+29905.134 Microsoft .NET Framework Version 4.8.03752
Installed Version: Professional ASP.NET and Web Tools 2019 16.4.462.24200 Azure App Service Tools v3.0.0 16.4.462.24200 C# Tools 3.4.1-beta4-20120-08+fa984e0202af4480c0273032da49cbbdeb32c582 Extensibility Message Bus 1.2.0 (d16-2@8b56e20) IntelliCode Extension 1.0 Microsoft Continuous Delivery Tools for Visual Studio 0.4 Microsoft JVM Debugger 1.0 Microsoft Library Manager 2.0.87+gbb515bf382 Microsoft MI-Based Debugger 1.0 Microsoft Visual Studio Tools for Containers 1.1 Mono Debugging for Visual Studio 16.5.24 (1fafd7e) NuGet Package Manager 5.4.0 Xamarin 16.4.000.313 (d16-4@793df40) Xamarin Designer 16.4.0.475 (remotes/origin/d16-4@ac250f5aa) Xamarin Templates 16.4.25 (579ee62) Xamarin.Android SDK 10.1.4.0 (d16-4/e44d1ae) Xamarin.Android Reference Assemblies and MSBuild support. Mono: fd9f379 Java.Interop: xamarin/java.interop/d16-4@c4e569f ProGuard: xamarin/proguard/master@905836d SQLite: xamarin/sqlite/3.28.0@46204c4 Xamarin.Android Tools: xamarin/xamarin-android-tools/d16-5@9f4ed4b Xamarin.iOS and Xamarin.Mac SDK 13.10.0.21 (02c4b3b)
Sample repo
https://github.com/PawKanarek/Bug-Reproduction-Repo-OneSignal-185-
Workaround Can you help me find any workaround for this issue?