我正在尝试使用Jenkins为Xamarin iOS项目构建CI管道,但由于MSBuild找不到对.NET Standard库的引用,我遇到了错误:
IDebugSettingService.cs(8,22): error CS0012: The type 'IDisposable' is defined in an assembly that is not referenced. You must add a reference to assembly 'netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'.
ViewModels/IPresentationTabViewModel.cs(17,15): error CS0012: The type 'MulticastDelegate' is defined in an assembly that is not referenced. You must add a reference to assembly 'netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'.
ViewModels/ICredentials.cs(17,10): error CS0012: The type 'Attribute' is defined in an assembly that is not referenced. You must add a reference to assembly 'netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'.
我可以在Mac构建计算机上的帐户上成功构建项目,但是Jenkins服务帐户始终在此处失败。我曾尝试清除并还原所有NuGet程序包,但MSBuild日志并没有太大帮助,尽管与Jenkins一起运行时,MSBuild加载的程序集似乎比我自己运行时要少得多。
这是我的项目设置的问题,还是Jenkins的问题?