1

I'm trying to create NuGet package which provides native DLLs and the MSBuild target to copy such DLLs into output directory of a .csproj project which would use the packet. I also need DLLs from NuGet package to be copied into output folders of other referencing projects and projects which are dependent upon such referencing projects. I use this advice to achieve that, and there are some problems:

  1. it works fine for the project (projA) which use NuGet package (afte building it, I see expected native DLLs in output directory).
  2. it works for another referencing project only if I add for the projA some fake file as a 'content' (i.e. file is not to be compiled, but it is to be published with a project).
  3. it doesn't work at all for projects, dependent from the referencing projects (i.e., using the work around from p.2, I managed to copy native DLLs into output directory of the referencing project, which refers to the projA, but I need the same for the project which depends on the referencing project).

How to achieve this? Now, as I fail to do it, I'm forced to use ugly .cmd script to copy native DLLs into output folders of projects which require it.

Community
  • 1
  • 1
Andrey G.A
  • 305
  • 4
  • 20
  • Use 'content' instead as shown in the [other answer](http://stackoverflow.com/a/30316946/1730559) to that question. – kjbartel Jan 19 '16 at 10:47
  • Possible duplicate of [Add native files from NuGet package to project output directory](http://stackoverflow.com/questions/19478775/add-native-files-from-nuget-package-to-project-output-directory) – kjbartel Jan 19 '16 at 10:48

0 Answers0