My Xamarin source code builds properly on local machine. But gives error of Microsoft.Bcl.Build.Tasks.dll. Could not load file or assembly on TFS Azure DevOps server.
I already have Condition="Exists('..\packages\Microsoft.Bcl.Build.1.0.21\build\Microsoft.Bcl.Build.targets')" in every .csproj of my solution still it gives same error while building the CI.
Error thrown at Azure DevOps:
packages\Microsoft.Bcl.Build.1.0.21\build\Microsoft.Bcl.Build.targets(97,5): Error MSB4062: The "EnsureBindingRedirects" task could not be loaded from the assembly D:\a\3\s\ACI_GPS\packages\Microsoft.Bcl.Build.1.0.21\build\Microsoft.Bcl.Build.Tasks.dll. Could not load file or assembly 'file:///D:\a\3\s\ACI_GPS\packages\Microsoft.Bcl.Build.1.0.21\build\Microsoft.Bcl.Build.Tasks.dll' or one of its dependencies. The system cannot find the file specified. Confirm that the declaration is correct, that the assembly and all its dependencies are available, and that the task contains a public class that implements Microsoft.Build.Framework.ITask. Process 'msbuild.exe' exited with code '1'.
Project builds successfully at local but not on TFS DevOps pipeline(CI). I'm trying multiple solution but nothing is working.