Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does MSBuild copy all DLLs locally, but on our Build Server it seems to ignore CopyLocal=True?

Tags:

msbuild

When I run MSBuild v4 locally, it builds nicely and copies all project and 3rd party DLLs into my website BIN folder.

However, when I run the exact same script on our Build server, it does not copy ANY of the referenced project DLLs or 3rd party DLLs into the website bin folder.

How do I get MSBuild to copy correctly on both environments? Is my .NET4 installation messed up?

The compilation in my MSBuild file is kicked off simply as follows:

<Target Name="Compile">
    <MSBuild Projects="..\MySolution.com.sln" Properties="Configuration=Debug">
    </MSBuild>
</Target>   
like image 750
willem Avatar asked Feb 28 '11 14:02

willem


2 Answers

This turned out to be a silly problem in the end. I'm guessing the VS2010 project files do not need to specifically have the "Private" attribute anymore, because mine were not there.

The problem was that I was using MSBuild v3.5 by accident, which was expecting these attributes.

As soon as I switched to using MSBuild v4 on our build server, the problem was solved.

like image 87
willem Avatar answered Nov 17 '22 15:11

willem


Can the build server reach the source locations you specify?

If they are on you local disk it will not see them and if they are on a shared disk it might not have access to that share or have it through another path?

like image 32
David Mårtensson Avatar answered Nov 17 '22 16:11

David Mårtensson