Xamarin LinkAssemblies build fails

I'm trying to build my Xamarin.Android app in Team Services and got the following error:

The "LinkAssemblies" task failed unexpectedly.
Java.Interop.Tools.Diagnostics.XamarinAndroidException: error XA2006: Could 
not resolve reference to 'System.Void.Android.Support.CustomTabs.CustomTabsIntent::LaunchUrl(Android.App.
Activity,Android.Net.Uri)' (defined in assembly 
'Microsoft.Azure.Mobile.Client, Version=4.0.1.0, Culture=neutral, 
PublicKeyToken=31bf3856ad364e35') with scope 
'Xamarin.Android.Support.CustomTabs, Version=1.0.0.0, Culture=neutral, 
PublicKeyToken=null'. When the scope is different from the defining 
assembly, it usually means that the type is forwarded. ---> 
Mono.Cecil.ResolutionException: Failed to resolve System.Void.Android.Support.CustomTabs.CustomTabsIntent::LaunchUrl(Android.App.Activity,Android.Net.Uri)
at Mono.Linker.Steps.MarkStep.MarkMethod(MethodReference reference)
at Mono.Linker.Steps.MarkStep.MarkInstruction(Instruction instruction)
at Mono.Linker.Steps.MarkStep.MarkMethodBody(MethodBody body)
at Mono.Linker.Steps.MarkStep.ProcessMethod(MethodDefinition method)
at Mono.Linker.Steps.MarkStep.ProcessQueue()
at Mono.Linker.Steps.MarkStep.Process()
at Mono.Linker.Steps.MarkStep.Process(LinkContext context)
at MonoDroid.Tuner.MonoDroidMarkStep.Process(LinkContext context)
at Mono.Linker.Pipeline.Process(LinkContext context)
at MonoDroid.Tuner.Linker.Process(LinkerOptions options, LinkContext& 
context)
at Xamarin.Android.Tasks.LinkAssemblies.Execute(DirectoryAssemblyResolver res)
--- End of inner exception stack trace ---
at Java.Interop.Tools.Diagnostics.Diagnostic.Error(Int32 code, Exception innerException, String message, Object[] args)
at Xamarin.Android.Tasks.LinkAssemblies.Execute(DirectoryAssemblyResolver res)
at Xamarin.Android.Tasks.LinkAssemblies.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.<ExecuteInstantiatedTask>d__26.MoveNext()

      

I see that it is probably package related Microsoft.Azure.Mobile.Client

, but not sure what I would need to do to resolve it (I am fairly new to Xamarin, so not sure what to do with this information).

My minSdkVersion is 21.

thank

+3


source to share


1 answer


Looks like the Microsoft.Azure.Mobile.Client package guys are having issues with Android.Support.CustomTabs library. See Published github issues: Issue 364 and Issue 361 . It looks like Microsoft.Azure.Mobile.Client version 4.0.0 might be built into Android.Support.CustomTabs version 25.3.1, but Microsoft.Azure.Mobile.Client version 4.0.1 might be built into Android.Support.CustomTabs version 23.3.0.



In my case, downgrading the nuget package Microsoft.Azure.Mobile.Client from 4.0.1 to 4.0.0 helped build and link my project.

+2


source







All Articles