hullunist
hullunist

Reputation: 1277

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?

Upvotes: 4

Views: 3598

Answers (1)

Matt Ward
Matt Ward

Reputation: 47907

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.

Upvotes: 3

Related Questions