ui icon indicating copy to clipboard operation
ui copied to clipboard

Unable to install on VS 2015 Xamarin iOS project use NuGet

Open nhaizere opened this issue 9 years ago • 11 comments

Could not install package 'OsmSharp 4.2.0.723'. You are trying to install this package into a project that targets 'Xamarin.iOS,Version=v1.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.

Looks like target framework xamarinios1 wasn't included. Is there any solution to install this package? Btw dependency protobuf-net 2.0.0.668 can't be installed by same reason.

nhaizere avatar Aug 07 '15 16:08 nhaizere

Note: This is an issue with the Nuget packages and Unified API.

xivk avatar Aug 19 '15 09:08 xivk

Updated according to the information found here:

http://developer.xamarin.com/guides/cross-platform/advanced/nuget/

Can you verify?

xivk avatar Aug 19 '15 09:08 xivk

@xivk looking at your commit you've just changed targets. But that type of project references different lib types. In your OsmSharp.iOS.UI Assembly its monotouch (http://i.imgur.com/S0baszN.png) but that new Xamarin iOS type project based on Xamarin.iOS Assembly so its definitely not a fix.

nhaizere avatar Aug 25 '15 12:08 nhaizere

I did the Xamarin.iOS Unified API upgrade for a larger project and it was actually quite a lot of work. Code changes as well. The automatic upgrade of Xamarin Studio caused the most work. Don't use it.

pauldendulk avatar Dec 02 '15 10:12 pauldendulk

@pauldendulk Thanks!

This commit should already have added support for unified API:

https://github.com/OsmSharp/ui/commit/a2508b8f4ac94225ac2192877ce589cf3fbb83de

I'll check what happens in the build process with the result.

xivk avatar Dec 02 '15 10:12 xivk

Using NuHelper with this command: nuhelper shortFrameworkName .NETPortable,Version=v4.0,Profile=Profile147 Results in this string for the .nuspec: portable-net403+sl50+win+wp80+Xamarin.iOS10+MonoAndroid10+MonoTouch10 I expect this to solve the problem.

pauldendulk avatar Dec 05 '15 11:12 pauldendulk

It is also be possible to generate the nuget package directly from the csproj > nuget spec osmsharp.ui.csproj -IncludeReferencedProjects -version 0.0.1-pre The more automation the better. Not sure when to use which (generating from csproj or nuspec).

pauldendulk avatar Dec 05 '15 12:12 pauldendulk

The protobuf-net dependency also doesn't install using Nuget on a fresh new 'Xamarin.iOS'. What a mess has this become all of a sudden.

xivk avatar Dec 08 '15 08:12 xivk

@xivk if there is a particular nuget target / moniker I should be using, let me know...

mgravell avatar Dec 08 '15 16:12 mgravell

@mgravell ,

NuHelper.exe shortFrameworkName .NETPortable,Version=v4.0,Profile=Profile136 portable-net40+sl50+wp80+win+MonoAndroid10+MonoTouch10

the above indicates that you(protobuf-net) already support MonoAndroid10+MonoTouch10

please make it happen shoud be as easy as renaming the nuspec, i hope

ahmedalejo avatar Mar 30 '16 17:03 ahmedalejo

Find out how to install successfully, just go to the packages that failed (protobuf-net) and install the latest version. :) Enjoy

Fox4148 avatar Dec 19 '16 14:12 Fox4148