简体   繁体   中英

Can't install NuGet-Packages (Xamarin Android project)

I have a problem with NuGet installing the "Xamarin.JOSE.JWT" package. I get the following error:

> 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.

Is this a known problem or is there a workaround for this?

Xamarin.JOSE.JWT 1.0.3 does not support Xamarin.Android projects. It only contains assemblies for .NET Framework 4.0.

Your options are:

  1. Find another NuGet package that does support Xamarin.Android projects.
  2. See if you can compile the Xamarin.JOSE.JWT project against Xamarin.Android.
  3. Open an issue on the Xamarin.JOSE.JWT GitHub repository.
  4. Try directly referencing the jose-jwt.dll from the NuGet package and see if it works with an Android project. This may not work if it is using parts of the .NET Framework not supported by Xamarin.Android.
  5. Use the Xamarin.JOSE.JWT NuGet package on the server side and not in the Android project.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM