
I've been trying to play with -D_GLIBCXX_DEBUG, but I'm having some problms with boost.program_options. Here's the code and the error. It's on an Ubuntu 8.04 box with g++4.2. #include <boost/program_options.hpp> using namespace boost; using namespace boost::program_options; int main(int ac, char* av[]) { options_description desc("Allowed options"); desc.add_options() ("help,h", "produce a help screen") ; variables_map vm; store(parse_command_line(ac, av, desc), vm); } $ make g++ -g -Wall -ggdb -ansi -I/home/pete/include -DDEBUG -D_GLIBCXX_DEBUG -L/home/pete/lib -lboost_program_options-mt test.cpp -o test /home/pete/tmp/ccJZlQNM.o: In function `basic_command_line_parser': /home/pete/include/boost/program_options/detail/parsers.hpp:41: undefined reference to `boost::program_options::detail::cmdline::cmdline(std::__debug::vector <std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&)' collect2: ld returned 1 exit status make: *** [test] Error 1 If I remove -D_GLIBCXX_DEBUG, the problem goes away. Any ideas of how to get this fixed, or am I doing something wrong? Thanks.
participants (1)
-
pete@mu.org