Question

This may be a no-brainer for longtime boost users, but I’m just getting into boost.

I built the full boost distribution and BCP to extract just the parts I need to put in my VisualStudio C++ project.

What I found is when I call bcp, it copies the source tree to the destination. It doesn’t copy the required compiled lib files though (for those modules that need it).

So when I build my project and include

#include "boost/program_options.hpp"

for example, I get a linker error:

*Error 1 error LNK1104: cannot open file 'libboost_program_options-vc100-mt-sgd-1_54.lib'*

So my question is this: should BCP also copy over the compiled LIB files as necessary ?

or

is it standard procedure for users of BOOST to manually copy those complied library files themselves?

Was it helpful?

Solution

I recently started experimenting with BCP. It seems like any boost modules that require libraries will not be copied, but instead they need to be built using bjam.

For example, when you run bcp on your code it will output some 'INFO' statements like this:
INFO: tracking source dependencies of library date_time due to presence of BOOST_DATE_TIME_DECL...
INFO: tracking source dependencies of library smart_ptr due to presence of "void sp_scalar_constructor_hook... Notice that in addition to the generated 'boost' folder containing a bunch of copied boost header files there will be a 'libs' folder along with Jam files (Jamroot, Jamfile.v2, etc). I think you need to cd to the directories with the Jamfiles and use bjam to build the needed libraries.

Maybe this answer will help: Building a subset of boost in windows

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top