我无法构建使用 Google API 的项目。我按照https://code.google.com/p/google-api-dotnet-client/wiki/Build上的构建说明进行操作。我收到如下几个错误:
Warning 5 The primary reference "Google.Apis" could not be resolved because
it has an indirect dependency on the framework assembly "System.Net.Http, Version=1.5.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which could not be resolved in the
currently targeted framework. ".NETFramework,Version=v4.0". To resolve this problem, either remove the reference "Google.Apis" or retarget your application to a framework
version which contains "System.Net.Http, Version=1.5.0.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a".
我也尝试使用 NuGet 来解决依赖关系,但我得到:
Install failed. Rolling back...
Install-Package : Could not install package 'Zlib.Portable 1.9.2'. You are trying to install this package into a project that targe
ts '.NETFramework,Version=v4.0', but the package does not contain any assembly references that are compatible with that framework.
For more information, contact the package author.
At line:1 char:16
+ install-package <<<< google.apis -pre
+ CategoryInfo : NotSpecified: (:) [Install-Package], InvalidOperationException
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand
文档说支持 4.0 Full Profile。我究竟做错了什么?