2
votes

I am trying to add the NLog package in my Xamarin Solution using Xamarin Studio. There is not a problem adding the library to a Xamarin Android Project. But it seems that NLog can not be added to my Xamarin iOS Project.

Package Console:

Adding NLog... Adding 'NLog 4.3.0-alpha3' to TestApp.iOS. Could not install package 'NLog 4.3.0-alpha3'. 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.

According to the nuget package description, it supports Xamarin.iOS.

1
To me, it looks like the .nuget is not configured correctly.. It is targeting MonoTouch10 thus the classic iOS, where it should be Xamarin.iOS10. The lib/MonoTouch10/NLog.dll inside the .nuget does properly ref Xamarin.iOS,Version=v1.0 so you can zip the .nuget and add a manual reference to it in project to unblock yourself.... Also fill a github issue.SushiHangover
I made already a github issue. github.com/NLog/NLog/issues/1152Stam
This should be fixed in NLog 4.3.0-alpha4Julian
Thanks it works now!Stam

1 Answers

0
votes

As confirmed, this is fixed in NLog 4.3.0-alpha4.

Please note that Xamarin Support is still in Alpha state.