James Lavery
James Lavery

Reputation: 949

Identifying culprits for numerous XA0106 warnings when building Xamarin.Forms app on Android

We have a Xamarin.Forms application which uses quite a few packages.

When building, we're getting hundreds of XA0106 warnings like this one:

/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets(2,2): Warning XA0106: Skipping Musterd.Droid.Resource.Attribute.MediaRouteControllerWindowBackground. Please check that your Nuget Package versions are compatible. (XA0106) (Musterd.Droid)

I know that this is because of mismatches between support libraries used by packages. The problem is finding out which one(s)!

Is there any tool or build setting I can use which will help me home on which packages are causing this and so which I can/should update?

Upvotes: 14

Views: 798

Answers (1)

JimBobBennett
JimBobBennett

Reputation: 2159

This can happen when the version of the Android SDK you are using is different to the version of the Android support packages used by your app. The support packages are versioned in a way that should match the compile time Android SDK.

The best fix is to always use the latest of both.

  • Update your Android SDK to have the latest stable installed.
  • Make sure your app compiles against the latest version in the project settings.
  • In the Android project update all NuGet Packages that start with Xamarin.Android to the latest version.

Upvotes: 0

Related Questions