Portable Class Library - how do I reference Monogame?

Finally got things up and running on the new box (for everything but iOS, at least) - next thing I’m trying to do is create a library that will contain the “scaffold” for my games - basic stuff like gamestate and asset management, and so forth.

I’m trying to create this as a portable class library, but the nuget packages are not playing ball: First I tried by making a PCL solution in it’s own right, after which, I tried the method given by @SimonDarksideJ here: How can I install the portable version of MonoGame?

In both cases, when trying to install the nuget package to the PCL, I get the following:
Install failed. Rolling back…
Install-Package : Could not install package ‘MonoGame-Portable 3.2.1’. You are trying to install this package into a project that targets
‘portable-net45+win+wpa81+wp80+MonoAndroid10+xamarinios10+MonoTouch10’, 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.
At line:1 char:1

  • Install-Package MonoGame-Portable
  •   + CategoryInfo          : NotSpecified: (:) [Install-Package], InvalidOperationException
      + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand

I can install the package to the .windows project when I use @SimonDarksideJ’s method, but then I cannot reference Monogame inside the PCL - no references are added by the package, and it is not available when I edit the references of the PCL project.

Any ideas?

The simple answer Ben is that you are using a newer version of Xanarin than the PCL was built with, they added some new targets which aren’t included in the NuGet PCL defition at present.
I do have a dev version of an updated package on the way, I’ll see if I can mail you a copy.

It is this target that is mucking it up “xamarinios10”, if you remove it for now it should let you continue :smiley:

Do we have any news on when the portable library maybe updated, I don’t mind giving it a crack myself although I’m fairly sure won’t get it right first time. I’ve been looking through the source have much to learn.