You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have support for custom linker flags creating NuGets from binding projects: they're stored either in a LinkWith attribute in the assembly or a manifest next to the assembly or in a binding resource package.
However, we don't have any support for additional linker flags when we link with libraries from a NuGet that don't come from a binding project (those automatically added to ResolvedFileToPublish by NuGet's logic, see https://github.com/xamarin/xamarin-macios/blob/main/dotnet/BundleContents.md for more info).
This is particularly common for NuGets that have support for numerous platforms, in which case the native library will likely be a C library, and not have any specific binding code for our platforms.
We should come up with a solution here.
Idea: add support for a manifest file next to the library. This file would have the same format as our other manifest file.
this file would be next to wherever libtest.a is in the NuGet (named libtest.manifest).
In theory these linker flags are only needed for static libraries, not for dylibs nor xcframeworks, but it should be trivial to add support for the manifest file for all types of libraries, so we should just do that as well (this could become useful if we use the manifest file to store more information in the future).
The text was updated successfully, but these errors were encountered:
We have support for custom linker flags creating NuGets from binding projects: they're stored either in a LinkWith attribute in the assembly or a manifest next to the assembly or in a binding resource package.
However, we don't have any support for additional linker flags when we link with libraries from a NuGet that don't come from a binding project (those automatically added to ResolvedFileToPublish by NuGet's logic, see https://github.com/xamarin/xamarin-macios/blob/main/dotnet/BundleContents.md for more info).
This is particularly common for NuGets that have support for numerous platforms, in which case the native library will likely be a C library, and not have any specific binding code for our platforms.
We should come up with a solution here.
Idea: add support for a manifest file next to the library. This file would have the same format as our other manifest file.
Example manifest file:
this file would be next to wherever
libtest.a
is in the NuGet (namedlibtest.manifest
).In theory these linker flags are only needed for static libraries, not for dylibs nor xcframeworks, but it should be trivial to add support for the manifest file for all types of libraries, so we should just do that as well (this could become useful if we use the manifest file to store more information in the future).
The text was updated successfully, but these errors were encountered: