May contain packages compiled with .net4.5 referenced by dnxcore50
I am compiling an application that targets dnxcore50 only.
I am trying to reference the nuget package which I know works fine when working with dnx451. When I do dnx . run
I get:
System.InvalidOperationException: Could not resolve the following dependencies for target infrastructure 'DNXCore, Version = v5.0':
it also suggests dnu restore
, but the package is there
This doesn't work explicitly for this package, so under what circumstances is it (if any)?
For it to work, did the package manager create a version compiled with dnxcore50?
Update
this diagram makes things a little clearer (copied from here )
source to share
Not. dnxcore50
indicates that you are running DNX on top of .NET Core. The only assemblies you can load into .NET Core are those targeting a compatible profile, in this case for example. dnxcore50
, dotnet
or one of the compatible portable profiles.
If you have an assembly built against the full .NET Framework (via net45
, net451
etc.), it will not work if on .NET Core, as the same APIs are not available.
source to share