Search code examples
c++visual-studioprojects-and-solutions

Visual Studio C++ Multi-Project Solutions


I typically use Linux to do all of my development, but have to use Visual Studio (2013 Professional, if that matters) for the project I'm working on now. I've used Visual Studio for projects in the past, and set up multi-project solutions where there were .lib and .dll files generated and all linked together by the compiler at the end to make an executable, or several. However, I've only ever set up these projects through the strange process of setting up dependencies, adding one project's directory to another projects include directory, adding the the library to the dependent projects linked libraries, etc. I'm used to the way Eclipse does this, where it give you a list of all the projects in your working set, and you can select what projects a given one is dependent on, and it will set all of this up for me. I've searched around and found nothing on how to do this simply in Visual Studio like I can in Eclipse. Is there no way to simply automate this task without resorting to the extreme of writing my own add-on, or is there one like this already in existence that I've yet to find?

Edit: I am referring to C++ projects


Solution

  • You must add a project-to-project reference in: Common Properties/Framework and References

    According to Microsoft, adding the Reference in Framework and References is the preferred method in Visual Studio 2010 and later. More info here: http://blogs.msdn.com/b/vcblog/archive/2010/02/16/project-settings-changes-with-vs2010.aspx