Reputation: 335
Trying to figure out how to package the following solution with Visual Studio 2017 Desktop Bridge (Application Packaging Project):
I added project 2 to Applications section of a package and buit it. In the target folder I have EXE (from project 2) and DLL (from project 1).
And the question is: how to correctly add the project 3 (native c++ library) to a package? I have x86 and x64 project configurations for this DLL.
Upvotes: 2
Views: 2328
Reputation: 13850
Here is how to do it - see screenshots below for illustration:
1) create a folder in your Winforms project as the target for your native DLL(s)
2) add a post-build event step to copy the native DLL to that folder
3) in that folder, mark the DLL as part of the project
4) Make sure properties are set to "Content" and "Copy to output"
5) now the packaging project will pick up the native DLL and include it in the package
Upvotes: 2