2013-07-23 1 views
1

Google API를 사용하는 프로젝트를 빌드 할 수 없습니다. 나는 빌드 지침을 https://code.google.com/p/google-api-dotnet-client/wiki/Build에 따라 갔다.Google API (.Net)로 프로젝트를 빌드 할 수 없습니다.

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의 전체 프로필이 지원했다. 내가 도대체 ​​뭘 잘못하고있는 겁니까?

+0

http://stackoverflow.com/questions/9431975/could-not-load-file-or-assembly-system-net-http-version-2 -0-0-0-in-mvc4-web-ap http://stackoverflow.com/questions/16756186/system-net-http-could-not-be-resolved-in-the-currently-targeted-framework- net-4 –

+0

비슷한 문제에 대해 불평하는 여러 사용자가 있기 때문에 어떤 솔루션이 효과가 있는지 알려주십시오. 감사! – peleyal

+0

@peleyal 나는이 프로젝트를 되돌아 보니 service.vb라는 프로젝트에 파일이 있기 때문에 실패했다고 생각한다. – Edwin

답변

1

나는 지금 일하고있다. 나는 그것을 정확히 무엇을 고정 모르겠다.

VS 2010에 이전 버전의 NuGet이 설치되었습니다. 관리자로 VS2010을 제거해야하므로 관리자로 처음 설치했을 수도 있습니다. NuGet을 제거한 후 최신 버전을 설치했습니다. 나는 그 때 성공한 package-install google.apis -prepackage-install google.apis.authentication -pre를 할 수있었습니다. 하지만 제 프로젝트는 여전히 컴파일되지 않습니다. 내 기억으로는 틀릴 수도 있지만, 내가 한 유일한 방법은 동일한 솔루션에서 별도의 프로젝트에서 Google API Lib 참조를 제거한 다음 컴파일 오류가 사라진 것입니다.

0

는 당신이 나에게 도움이, latest NuGet을 설치해야합니다

+0

NuGet을 최신 버전으로 설치했는데 문제가 수정되었을 수 있습니다. – Edwin

관련 문제