C++ – Boost linking, Visual Studio & version control

boostcversion controlvisual studio

I'm using Visual Studio 2008, and writing some stuff in C++. I'm using a Boost library (that is not header only).

So, linking to Boost requires one to add the directory to Boost binaries to the project's "additional linker paths" setting.

However, doesn't this conflict with source control? If I check in the project files, wouldn't the absolute path to Boost libs on my computer also be included in them?

I obviously don't want this to happen, so what should I do? Just adding the Boost directory to "Visual C++ Directories/Libraries" doesn't work.

Best Answer

Adding the Boost paths to "Visual C++ Directories" should work. You should add include path <Full path here>\boost_1_39_0 (no boost at the end)
and library path <Full path here>\boost_1_39_0\bin.v2\lib (bin.v2 is a stage dir that could be different in you case).

Personally, I store boost sources in my source control and use relative paths in project settings.