Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   C++ (http://www.velocityreviews.com/forums/f39-c.html)
-   -   boost::program_options (http://www.velocityreviews.com/forums/t501722-boost-program_options.html)

zade 04-20-2007 01:49 PM

boost::program_options
 
Hi all
boost::program_options needs be builled into libraries, static or
dynamic. I use MSVC7.1 to build the boost::program_options for my
project .In my .cpp file , I write:

namespace po = boost::program_options;

struct CommandLineParser
{
CommandLineParser()
:desc("options")
{}
po::options_description desc;
po::variables_map vm;
};
But the compiler says error:
compiling....
Linking to lib file: libboost_program_options-vc71-mt-gd-1_33_1.lib
Linking...
commandlineparser.obj : error LNK2019: unresolved symbols "public:
__thiscall
boost::program_options::options_description::optio ns_description(class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &)"

it is clear that the lib"libboost_program_options-vc71-mt-
gd-1_33_1.lib" is linked, so why??

Thanks


Zeppe 04-20-2007 03:12 PM

Re: boost::program_options
 
zade wrote:
> Hi all
> boost::program_options needs be builled into libraries, static or
> dynamic. I use MSVC7.1 to build the boost::program_options for my
> project .In my .cpp file , I write:


The question is OT here, you should ask in a Microsoft related ng.
Anyway, have you built your libraries with the same version of the
compiler that you are using for your program? Are you linking the
correct version of the libraries (i.e., same threading model, same Debug
information, and so)?

Regards,

Zeppe


All times are GMT. The time now is 11:42 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.