Boost logo

Boost Users :

Subject: [Boost-users] linking error while using Boost-regex and Stlport in the same project
From: ashish (ashish.lahane_at_[hidden])
Date: 2008-12-12 09:04:50


>
Hi,

I'm working on a project which needs both boost-regex, and STLPORT. When these
two libraries are used individually for some sample examples, they work fine.
But when used both in the same project, I get linking errors as follows:

>______________________________________________________________________
 main/main.cpp:6: instantiated from here
/home/kpendyal/software/STLport-5.1.5/stlport/stl/_algobase.c:374: warning:
unused parameter '__comp2'
/usr/bin/ld: warning: libstdc++.so.5, needed by
/home/kpendyal/software/xerces-c_2_8_0/lib/libxerces-c.so, may conflict with
libstdc++.so.6
main/main.o(.gnu.linkonce.t._ZN5boost9re_detail12perl_matcherIPKcN8stlp_
std9allocatorINS_9sub_matchIS3_EEEENS_12regex_traitsIcNS_16cpp_regex_
traitsIcEEEEE11match_matchEv+0xa3):
In function `boost::re_detail::perl_matcher<char const*,
stlp_std::allocator<boost::sub_match<char const*> >, boost::regex_traits<char,
boost::cpp_regex_traits<char> > >::match_match()':
: undefined reference to `boost::match_results<char const*,
stlp_std::allocator<boost::sub_match<char const*> >
>::maybe_assign(boost::match_results<char const*,
stlp_std::allocator<boost::sub_match<char const*> > > const&)'
main/main.o(.gnu.linkonce.t._ZN5boost12regex_searchIPKcN8stlp_
std9allocatorINS_9sub_matchIS2_EEEEcNS_12regex_traitsIcNS_16cpp_
regex_traitsIcEEEEEEbT_SC_RNS_13match_resultsISC_T0_EERKNS_11basic_
regexIT1_T2_EENS_15regex_constants12_match_flagsESC_+0x8e):
In function `bool boost::regex_search<char const*,
stlp_std::allocator<boost::sub_match<char const*> >, char,
boost::regex_traits<char, boost::cpp_regex_
traits<char> > >(char const*, char
const*, boost::match_results<char const*,
stlp_std::allocator<boost::sub_match<char const*> > >&, boost::basic_
regex<char,
boost::regex_traits<char, boost::cpp_regex_traits<char> > > const&,
boost::regex_constants::_match_flags, char const*)':
: undefined reference to `boost::re_detail::perl_matcher<char const*,
stlp_std::allocator<boost::sub_match<char const*> >, boost::regex_traits<char,
boost::cpp_regex_traits<char> > >::construct_init(boost::basic_regex<char,
boost::regex_traits<char, boost::cpp_regex_traits<char> > > const&,
boost::regex_constants::_match_flags)'
main/main.o(.gnu.linkonce.t._ZN5boost9re_detail11raise_errorINS_
20regex_traits_wrapperINS_12regex_traitsIcNS_16cpp_regex_
traitsIcEEEEEEEEvRKT_NS_15regex_constants10error_typeE+0xa3):
In function `void
boost::re_detail::raise_error<boost::regex_traits_wrapper<boost::regex_
traits<char,
boost::cpp_regex_traits<char> > >
>(boost::regex_traits_wrapper<boost::regex_traits<char,
boost::cpp_regex_traits<char> > > const&, boost::regex_constants::error
_type)':
: undefined reference to
`boost::re_detail::raise_runtime_error(stlp_std::runtime
_error const&)'
main/main.o(.gnu.linkonce.t._ZN5boost9re_detail18basic_regex
_parserIcNS_12regex_traitsIcNS_16cpp_regex_traitsIcEEEEE4failENS_
15regex_constants10error_typeEi+0x108):
In function `boost::re_detail::basic_regex_parser<char,
boost::regex_traits<char, boost::cpp_regex_traits<char> >
>::fail(boost::regex_constants::error_type, int)':
: undefined reference to
`boost::regex_error::regex_error(stlp_std::basic_string<char,
stlp_std::char_traits<char>, stlp_std::allocator<char> > const&,
boost::regex_constants::error_type, int)'
collect2: ld returned 1 exit status
make: *** [ctoolkit] Error 1

______________________________________________________________________
>
>
I tried to build boost with STLPORT, but never could get the library with '-p'
in it's name, which I suppose is required here. How can I get it, or is there
some other way????

Please help asap...
>


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