I am trying to build a .csproj that references some projects in a solution. These links are marked CopyLocal=False . And this is the desired behavior.
I create it for CI using MSBuild, so I set the output folder via /p:OutputPath="some output dir" . I also set /p:SolutionDir="path to the solution" to correctly resolve some NuGet links.
The problem is this: when I specify OutputPath with an absolute path to the output directory (for example, d:\solution\build\buildgroupsubfolder ), then MSBuild copies each dependency to the output directory, I don't know why this is done. And if I specify the output path with a relative path (for example ..\..\..\..\..\build\buildgroupsubfolder ), then MSBuild correctly processes CopyLocal=False and does not copy the links to the output directory.
We had some kind of nesting in our solution, projects are divided into groups, so we want them to be embedded in subfolders. And I want to be able to specify the build path relative to the base build path, and not the path to the project itself.
Why does MSBuild ignore CopyLocal = false when an absolute path is specified and correctly processes it when a relative path is specified?
source share