Linker error when using boost threads
I'm trying to use the boost threads, but when running the program i get this:
LINK : fatal error LNK开发者_开发技巧1104: cannot open file 'libboost_date_time-vc100-mt-gd-1_46.lib'
The directories I've included in the linker, are: c:\boost_1_46_0\libs\ and c:\boost_1_46_0\boost.
And I am using Visual Studio Express 2010.Thanks.
Specify $(BOOSTROOT)/lib as 'additional library directory' for the linker. ( Note: it is NOT libs with an s )
This assumes that you have built the boost libraries using the visual studio compiler. From the discussion in the comments, it seems you have not done this.
I recomend, instead of trying to build the libraries yourself, you use the installer to get pre-built binaries. Here is the installer: http://www.boostpro.com/download/
精彩评论