Search code examples
c#asp.net-mvcvisual-studio-2010tfs

TFS and referenced DLLs


We are using TFS and VS 2010.

I have been working on a project that is using TFS as source control. I have quite a few dlls that I have downloaded (such as log4net) and referenced in my project.

When a new programmer connected to TFS and got my project out of source control, it failed to build as it said it was missing all these referenced dlls.

What did I do wrong here? How can I include those referenced DLLs in source control. Do I need to add all these dlls to my project before referencing them? when I referenced them, I just browsed to where they were on my file system.


Solution

  • I've found the best practice for 3rd party DLLs is to create a "Library" folder in your sln/proj file structure and copy all the necessary DLLs into this local folder for reference. You'll also want to make sure these DLLs are checked into source control. This way, everyone who works on the project gets the exact same versions of all DLLs, and the reference paths are exactly the same.

    Referencing 3rd party libs in a arbitrary download or install location will be problematic, because it will require all developers to maintain the same download structure for all DLLs. Also, if everyone references DLLs outside of the project structure, it's harder to guarantee that everyone's on the same version.

    The other option would be to have everyone install the DLLs into the GAC, but that can be a real pain too, especially with version management and deployment.