NuGet for UWP apps cannot call C++ libraries
sriniketana opened this issue · 3 comments
I have a C# library for UWP packaged into an NuGet package. This C# library in turn calls a C++ library internally. When packaged as a NuGet package, the C# library is not able to find and call the C++ library.
My nupkg structure is given below - as documented in https://docs.nuget.org/create/uwp-create#native-light-up
runtimes\win10-x86\lib\uap10.0
---- MyCSharpLib.dll
---- MyCSharpLib.pri
runtimes\win10-x86\native
---- MyCPPLib.dll
---- MyCPPLib.winmd
I've also tried placing the CPP lib in the same folder as the C# lib but still the issue persists.
Same issue for me, this is driving me crazy. By any chance did you solve it since March?
@koenigsbier I took help from this suggestion - #1221 (comment)
Use corflags to generate arch independent version of the DLL.
I do not see any mention of what isnt working or what is expected here.
Runtime/
should always be used with ref/
, runtime just does a copy to the output folder at publish time.