MSBuild doesn't copy references (DLL files) if using project dependencies in solution

前端 未结 19 1338
Happy的楠姐
Happy的楠姐 2020-11-22 07:24

I have four projects in my Visual Studio solution (everyone targeting .NET 3.5) - for my problem only these two are important:

  1. MyBaseProject &
19条回答
  •  名媛妹妹
    2020-11-22 07:51

    The issue I was facing was I have a project that is dependent on a library project. In order to build I was following these steps:

    msbuild.exe myproject.vbproj /T:Rebuild
    msbuild.exe myproject.vbproj /T:Package
    

    That of course meant I was missing my library's dll files in bin and most importantly in the package zip file. I found this works perfectly:

    msbuild.exe myproject.vbproj /T:Rebuild;Package
    

    I have no idea why this work or why it didn't in the first place. But hope that helps.

提交回复
热议问题