Xamarin nuget package updates are not compatible. How can I update the nuget packages in Visual Studio for Mac Community?

Kim Strasser 1,321 Reputation points
2022-08-17T11:32:39.307+00:00

I want to update my nuget packages in Visual Studio for Mac Community 8.10.25 (build 2) but the following two updates always fail in my Android project:

Package Xamarin.Firebase.Messaging 122.0.0.7 is not compatible with monoandroid11.0 (MonoAndroid,Version=v11.0). Package Xamarin.Firebase.Messaging 122.0.0.7 supports:

  • monoandroid12.0 (MonoAndroid,Version=v12.0)
  • net6.0-android31.0 (.NETCoreApp,Version=v6.0)

    Package Xamarin.GooglePlayServices.Base 118.1.0 is not compatible with monoandroid11.0 (MonoAndroid,Version=v11.0). Package Xamarin.GooglePlayServices.Base 118.1.0 supports:

    • monoandroid12.0 (MonoAndroid,Version=v12.0)
    • net6.0-android31.0 (.NETCoreApp,Version=v6.0)

How can I upgrade to monoandroid12.0 (MonoAndroid,Version=v12.0) and net6.0-android31.0 (.NETCoreApp,Version=v6.0) so that I can install the nuget package updates?

Developer technologies | .NET | Xamarin
0 comments No comments
{count} votes

Accepted answer
  1. Anonymous
    2022-08-18T03:02:53.247+00:00

    Hello,

    Please change your Target framework to Android 12. To access the Target Framework setting in Visual Studio for Mac, right-click the project name and select Options; this opens the Project Options dialog. In this dialog, navigate to Build > General as shown there like this document:

    Best Regards,

    Leon Lu


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.