2016-03-21 238 views
4

我有一個NuGet安裝「Xamarin.JOSE.JWT」包的問題。我收到以下錯誤:無法安裝NuGet包(Xamarin Android項目)

> Could not install package 'Xamarin.JOSE.JWT 1.0.3'. You are trying to 
> install this package into a project that targets 
> 'MonoAndroid,Version=v6.0', but the package does not contain any 
> assembly references or content files that are compatible with that 
> framework. For more information, contact the package author. 

這是已知問題還是有解決方法?

回答

3

Xamarin.JOSE.JWT 1.0.3不支持Xamarin.Android項目。它只包含.NET Framework 4.0的程序集。

的選項有:

  1. 找到另一個NuGet包確實支持Xamarin.Android項目。
  2. 看看你是否可以針對Xamarin.Android編譯Xamarin.JOSE.JWT項目。
  3. 在Xamarin.JOSE.JWT GitHub存儲庫中打開一個問題。
  4. 嘗試直接引用NuGet包中的jose-jwt.dll並查看它是否適用於Android項目。如果它使用Xamarin.Android不支持的.NET Framework的某些部分,這可能不起作用。
  5. 在服務器端使用Xamarin.JOSE.JWT NuGet包,而不是在Android項目中使用。
相關問題