1

Closed

NdefLibrary 0.5 could not be installed by NuGet

description

It seems that NdefLibrary 0.5 project does not specify any target framework version and it's the cause of the failure on installation.The installation log:------Successfully installed 'NdefLibrary 0.5.0.0'.Successfully uninstalled 'NdefLibrary 0.5.0.0'.Install failed. Rolling back...Could not install package 'NdefLibrary 0.5.0.0'. You are trying to install this package into a project that targets '.NETCore,Version=v4.5', but the package does not contain any assembly references that are compatible with that framework. For more information, contact the package author.

file attachments

Closed Dec 15, 2012 at 12:21 PM by mopius
Summary: we found that the issue is related to an old version of the NuGet Package Manager extension. Please update the extension in Visual Studio in order to install the library! I've added further instructions in the documentation section.

comments

mopius wrote Oct 19, 2012 at 12:45 PM

Thanks for the report!
I've tested NuGet package integration with Windows 8 Store apps, Windows Phone 8 as well as other .NET 4.5+ apps. All seems to work fine. What kind of project are you trying to integrate the NDEF library to? Are you using Windows 8 RTM + VS 2012 final, or are you running a consumer preview version?

wrote Oct 19, 2012 at 2:02 PM

espresso3389 wrote Oct 19, 2012 at 2:02 PM

I'm working with VS2012 RTM on Windows 8 Pro (x64) RTM.
Even with 0.9.0.0 released recently would not be installed.
The atachment is the screenshot of the error when I tried to install NdefLibrary from NuGet Package Manager.

And, when I downloaded the 0.9.0.0 source code and launch the solution with VS2012, it shows the following warning:

The reference assemblies for framework ".NETPortable,Version=v4.5,Profile=Profile78" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend.

I don't know what Profile=Profile78 means...

mopius wrote Oct 22, 2012 at 2:30 PM

Ok, I could reproduce your issue. Seems like your system needs to have all the SDKs installed that are targeted by the library.

Quick solution for now is to download the library project, open it with VS 2012, go to the project properties. Now, change the Target Frameworks to only include the SDKs you have installed (e.g., for Windows 8 Store apps) and recompile the library.

I'll check how to improve that for the next library version release, so that the lib can be used without the need to have all SDKs installed!

radostlaf wrote Nov 12, 2012 at 10:38 AM

I have the same problem, i have to make a small application for writing tags. so how do you solve the problem with installation of NuGet Ndef library

mopius wrote Nov 12, 2012 at 12:10 PM

The current version of the portable class library can apparently only be installed when you have both the Windows 8 SDK + the Windows Phone 8 SDK installed on your computer. Irrespective if you create a Windows 8 or a Windows Phone 8 project. It's just that both SDKs need to be present.

I'm currently looking into this issue and will hopefully find a solution to make the library also easily installable on computers that only have one of those two SDKs installed. If you have any pointers on how to best do that, I'd greatly appreciate :)

radostlaf wrote Nov 13, 2012 at 9:45 AM

i hope this will help someone with similar of my problem, what i have been missing is to update your NuGet package manager to the latest version.

Visual Studio File Menu --> Tools --> Extensions and Updates --> Updates --> Visual Studio Gallery --> NuGet --> Update

mopius wrote Nov 13, 2012 at 10:35 AM

radostlaf, thanks for the update! Does it now work for you, even if you only have the Windows 8 SDK and not the WP8 SDK installed?

mopius wrote Dec 15, 2012 at 12:18 PM

Summary: we found that the issue is related to an old version of the NuGet Package Manager extension. Please update the extension in Visual Studio in order to install the library! I've added further instructions in the documentation section.

wrote Dec 15, 2012 at 12:21 PM

wrote Feb 14, 2013 at 8:16 PM

wrote May 16, 2013 at 10:17 AM