Visual Studio 2010 Publish Web feature not including all DLLs

后端 未结 13 2043
梦毁少年i
梦毁少年i 2021-01-31 07:14

I have an ASP.NET MVC 2 application.

  • Web project contains a reference to SomeProject
  • SomeProject contains references to ExternalAssembly1 and ExternalAs
13条回答
  •  北恋
    北恋 (楼主)
    2021-01-31 08:03

    I had the same problem with VS2010 and a WCF Service Application.

    It turns out that if your (directly or indirectly) referenced DLL's are deployed to GAC, the VS publishing feature excludes them. Once I removed the assemblies from GAC, publishing feature started working as expected.

    I guess VS is assuming that if your assemblies can be located in GAC on the machine you build, they will be located in GAC on the target machine as well. At least in my case this assumption is false.

提交回复
热议问题