Vs2008 post an issue with unmanaged DLLs

I have a collection of unmanaged dlls with a C # wrapper around them that I am calling from a C # project. I added a build event line that looks like this:

mkdir ..\Release
mkdir ..\Debug
copy ..\..\Includes\*.dll ..\Release\*.dll
copy ..\..\Includes\*.dll ..\Debug\*.dll

      

The problem is that when I go to publish the application these DLLs are not included, and publishing is worse than useless as it creates an application that runs until you call one of those DLLs.

So how do I enable unmanaged DLLs when publishing a project?

+1


source to share


2 answers


And the answer is, don't post this, instead use the Windows Installer as described here.



+2


source


I am currently researching the same issue. The literature on this topic is very scarce!



The only solution I see is to inject the unmanaged DLL as an embedded resource inside the assembly and programmatically retrieve it on the execution path before calling any functions.

+1


source







All Articles