Quantcast
Channel: MSBuild forum
Viewing all articles
Browse latest Browse all 2763

Missing DLL when you build using command line devenv instead of Visual Studio UI

$
0
0

Hello,

In summary :

ExeApp.Exe à A.dllà B.dll

  • VS UI Build output : All files
  • VS command line Build output : No B.dl

Steps to reproduce :

Using Visual Studio (C#) :

  • File/New/Project/WindowsFormApplication - (ExeApp.Exe)
  • Add to the solution a  new class library project – (Assembly named A.dll)
  • Add to the solution a  new class library project – (Assembly named B.dll)
  • Create a project reference : ExeApp.Exe references A.dll
  • Create a project reference : A.dll references B.dll

Note : do not code anything.

1°/ Build using Visual Studio UI.

Output of project ExeApp.Exe contains :

  • ExeApp.Exe
  • A.dll
  • B.dll

2°/ Clean manually (not using Visual Studio Clean) output of project ExeApp.Exe, and build using the following command line

"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv" "YourSolution.sln" /Build "Release|Any CPU" /project "ExeApp.csproj"

Output of project ExeApp.Exe contains :

  • ExeApp.Exe
  • A.dll

My questions :

The result of the 2 build are different. This is not the behaviour I expected. Is it a known issue ?

Why do we have this difference ?

Annex :

Note 1: Issue reproduced with VS2010 and VS2013

Note 2 : If you build and then clean using Visual Studio UI, ExeApp.Exe and A.dll are correctly cleaned, but B.dll remains in the output folder.

Note 3 : If you make some code in ExeApp.exe that use code from A.dll, and some code in A.dll that use code in B.dll, B.dll is always in the output.

Regards,

Jean-Pierre


Viewing all articles
Browse latest Browse all 2763

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>