Boost logo

Boost Users :

Subject: Re: [Boost-users] program_options and BOOST_ALL_NO_LIB=1
From: Gianni Ambrosio (gianni.ambrosio_at_[hidden])
Date: 2011-03-09 04:35:46


Hi Diederick,
it seems link errors directly related to program_options lib. I used
property tree lib without the need of any lib to link against. So, which
is the benefit of using BOOST_ALL_NO_LIB if I need to link against boost
libs?

Anyway, here are the errors:

error LNK2001: unresolved external symbol "void __cdecl
boost::program_options::validators::check_first_occurrence(class
boost::any const &)"
(?check_first_occurrence_at_validators@program_options_at_boost@@YAXABVany_at_3@@Z)
error LNK2001: unresolved external symbol "class
std::basic_ostream<char,struct std::char_traits<char> > & __cdecl
boost::program_options::operator<<(class std::basic_ostream<char,struct
std::char_traits<char> > &,class
boost::program_options::options_description const &)"
(??6program_options_at_boost@@YAAAV?$basic_ostream_at_DU?$char_traits_at_D@std@@@std@@AAV23_at_ABVoptions_description_at_01@@Z)
error LNK2001: unresolved external symbol "public: __thiscall
boost::program_options::invalid_option_value::invalid_option_value(class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &)"
(??0invalid_option_value_at_program_options_at_boost@@QAE_at_ABV?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@@Z)
error LNK2001: unresolved external symbol "public: class
boost::program_options::variable_value const & __thiscall
boost::program_options::abstract_variables_map::operator[](class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &)const "
(??Aabstract_variables_map_at_program_options_at_boost@@QBEABVvariable_value_at_12@ABV?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@@Z)
error LNK2001: unresolved external symbol "class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > boost::program_options::arg"
(?arg_at_program_options_at_boost@@3V?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@A)
error LNK2001: unresolved external symbol "public: void __thiscall
boost::program_options::detail::cmdline::set_additional_parser(class
boost::function1<struct std::pair<class std::basic_string<char,struct
std::char_traits<char>,class std::allocator<char> >,class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > >,class std::basic_string<char,struct
std::char_traits<char>,class std::allocator<char> > const &>)"
(?set_additional_parser_at_cmdline@detail_at_program_options_at_boost@@QAEXV?$function1_at_U?$pair_at_V?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@V12@@std@@ABV?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@2@@4@@Z)
error LNK2001: unresolved external symbol "public: class
std::vector<class boost::program_options::basic_option<char>,class
std::allocator<class boost::program_options::basic_option<char> > >
__thiscall boost::program_options::detail::cmdline::run(void)"
(?run_at_cmdline@detail_at_program_options_at_boost@@QAE?AV?$vector_at_V?$basic_option_at_D@program_options_at_boost@@V?$allocator_at_V?$basic_option_at_D@program_options_at_boost@@@std@@@std@@XZ)
error LNK2001: unresolved external symbol "public: void __thiscall
boost::program_options::detail::cmdline::set_options_description(class
boost::program_options::options_description const &)"
(?set_options_description_at_cmdline@detail_at_program_options_at_boost@@QAEXABVoptions_description_at_34@@Z)
error LNK2001: unresolved external symbol "public: void __thiscall
boost::program_options::detail::cmdline::style(int)"
(?style_at_cmdline@detail_at_program_options_at_boost@@QAEXH_at_Z)
error LNK2001: unresolved external symbol "public: __thiscall
boost::program_options::detail::cmdline::cmdline(class std::vector<class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> >,class std::allocator<class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > > > const &)"
(??0cmdline_at_detail@program_options_at_boost@@QAE_at_ABV?$vector_at_V?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@V?$allocator_at_V?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@@2@@std@@@Z)
error LNK2001: unresolved external symbol "public: class
boost::program_options::options_description_easy_init __thiscall
boost::program_options::options_description::add_options(void)"
(?add_options_at_options_description_at_program_options_at_boost@@QAE?AVoptions_description_easy_init_at_23@XZ)
error LNK2001: unresolved external symbol "public: __thiscall
boost::program_options::options_description::options_description(class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &,unsigned int)"
(??0options_description_at_program_options_at_boost@@QAE_at_ABV?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@I_at_Z)
error LNK2001: unresolved external symbol "public: class
boost::program_options::options_description_easy_init & __thiscall
boost::program_options::options_description_easy_init::operator()(char
const *,char const *)"
(??Roptions_description_easy_init_at_program_options_at_boost@@QAEAAV012_at_PBD0@Z)
error LNK2001: unresolved external symbol "public: class
boost::program_options::options_description_easy_init & __thiscall
boost::program_options::options_description_easy_init::operator()(char
const *,class boost::program_options::value_semantic const *,char const
*)"
(??Roptions_description_easy_init_at_program_options_at_boost@@QAEAAV012_at_PBDPBVvalue_semantic_at_12@0_at_Z)
error LNK2001: unresolved external symbol "private: virtual void
__thiscall
boost::program_options::value_semantic_codecvt_helper<char>::parse(class
boost::any &,class std::vector<class std::basic_string<char,struct
std::char_traits<char>,class std::allocator<char> >,class
std::allocator<class std::basic_string<char,struct
std::char_traits<char>,class std::allocator<char> > > > const
&,bool)const "
(?parse@?$value_semantic_codecvt_helper_at_D@program_options_at_boost@@EBEXAAVany_at_3@ABV?$vector_at_V?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@V?$allocator_at_V?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@@2@@std@@_N_at_Z)
error LNK2001: unresolved external symbol "public: __thiscall
boost::program_options::variables_map::variables_map(void)"
(??0variables_map_at_program_options_at_boost@@QAE_at_XZ)
error LNK2001: unresolved external symbol "public: static unsigned int
const
boost::program_options::options_description::m_default_line_length"
(?m_default_line_length_at_options_description_at_program_options_at_boost@@2IB)
error LNK2001: unresolved external symbol "class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > __cdecl boost::program_options::to_internal(class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &)"
(?to_internal_at_program_options_at_boost@@YA?AV?$basic_string_at_DU?$char_traits_at_D@std@@V?$allocator_at_D@2@@std@@ABV34@@Z)
error LNK2001: unresolved external symbol "public: virtual char const *
__thiscall boost::program_options::validation_error::what(void)const "
(?what_at_validation_error_at_program_options_at_boost@@UBEPBDXZ)
error LNK2001: unresolved external symbol "void __cdecl
boost::program_options::notify(class
boost::program_options::variables_map &)"
(?notify_at_program_options_at_boost@@YAXAAVvariables_map_at_12@@Z)
error LNK2001: unresolved external symbol "void __cdecl
boost::program_options::store(class
boost::program_options::basic_parsed_options<char> const &,class
boost::program_options::variables_map &,bool)"
(?store_at_program_options_at_boost@@YAXABV?$basic_parsed_options_at_D@12_at_AAVvariables_map_at_12@_N_at_Z)

Regards
Gianni

Il 3/9/2011 9:59 AM, Diederick C. Niehorster ha scritto:
> What errors? Just because you ask it not to link to any boost library
> doesn't mean that program_options can work without its compiled
> parts... You'll have to link against somehting...
>
> Best,
> Dee
>
> On Wed, Mar 9, 2011 at 16:56, Gianni Ambrosio
> <gianni.ambrosio_at_[hidden]> wrote:
>> Dear All,
>> I have a simple test using program_options but even if I set
>> BOOST_ALL_NO_LIB=1 the linker gives me errors. Any idea?
>>
>> Regards
>> Gianni
>>
>>
>>
>>
>>
>> _______________________________________________
>> Boost-users mailing list
>> Boost-users_at_[hidden]
>> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>
>
>
>
> -----
> No virus found in this message.
> Checked by AVG - www.avg.com
> Version: 10.0.1204 / Virus Database: 1497/3492 - Release Date: 03/08/11


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net