xamarin-macios icon indicating copy to clipboard operation
xamarin-macios copied to clipboard

NET6 BindingProjects requiring NativeReference makes use of ScriptingBridge API difficult

Open chamons opened this issue 3 years ago • 1 comments

Some APIs like ScriptingBridge require creating subclasses using binding projects without having a native library to bind.

Example: https://github.com/xamarin/xamarin-macios/blob/main/tests/scriptingbridge/finder.cs

This worked in legacy, but during the transition to NET6 this stopped worked, as found in this issue.

MSBuild : error MM7068: Can't create a binding resource package unless there are native references in the binding project. [/Users/sergey/Downloads/net6nativeBindingsError-master/net6/NativeBindingsLib/NativeBindingsLib.csproj]

It should be simple enough to remove this restriction, as we now have a valid use case.

chamons avatar Jul 13 '22 20:07 chamons

FYI @rolfbjarne

chamons avatar Jul 13 '22 20:07 chamons