尝试昨天发布的新的.Net Core 1.0.
我无法让 WindowsAzure.Storage库工作.
编译器抱怨多个依赖项不支持.NETCoreApp,Version = v1.0.
我无法让 WindowsAzure.Storage库工作.
编译器抱怨多个依赖项不支持.NETCoreApp,Version = v1.0.
The dependency Microsoft.Data.Edm 5.6.4 does not support framework .NETStandard,Version=v1.5.
The dependency Microsoft.Data.OData 5.6.4 does not support framework .NETStandard,Version=v1.5.
The dependency Microsoft.Data.Services.Client 5.6.4 does not support framework .NETStandard,Version=v1.5.
The dependency System.Spatial 5.6.4 does not support framework .NETStandard,Version=v1.5.
这是否意味着WindowsAzure.Storage SDK还没有为.Net Core 1.0做好准备了吗?
解决方法
WindowsAzure.Storage
supports .NET Standard,但它的依赖项没有. Microsoft.Data.OData和System.Spatial尚不支持.NET Standard.
library source建议将以下导入属性添加到project.json中的frameworks部分:
"imports": [ "dnxcore50","portable-net451+win8" ]
在较新的基于csproj的项目中,PackageTargetFallback属性完成同样的事情:
<PropertyGroup> <PackageTargetFallback>dnxcore50;portable-net451+win8</PackageTargetFallback> </PropertyGroup>