|
Boost Users : |
Subject: Re: [Boost-users] installing boost_1_47_0
From: rudy b (rudykeram_at_[hidden])
Date: 2011-08-10 06:59:24
I tried -lboost_system, but it doesn't seem that the compiler
understand this link !!
what does this mean?
--Rudy
On Aug 9, 11:39 pm, "Claas H. Köhler" <claas.koeh..._at_[hidden]> wrote:
> Hi!
>
> Building boost_1_47_0 I with gcc-4.6 -std=c++0x I encountered the errors
> listed below. If I exchange in
> libs/signals/src/named_slot_map.cpp
>
> [named_slot_map.cpp:105]
> groups.erase(group); [old]
> groups.erase( const_group_iterator(group) ); [new]
>
> [named_slot_map.cpp:128]
> if (empty(g)) groups.erase(g++); [old]
> if (empty(g)) groups.erase( const_group_iterator(g++) );[new]
>
> I am wondering if this is a boost issue or a gcc issue, since the
> compiler should actually be able to convert a map::iterator into a
> map::const_iterator by default, or am I mistaken here?
>
> Regards
> Claas
>
> The compiler error in its full beauty:
>
> libs/signals/src/named_slot_map.cpp: In member function void
> boost::signals::detail::named_slot_map::disconnect(const
> boost::signals::detail::stored_group&):
> libs/signals/src/named_slot_map.cpp:105:23: error: call of overloaded
> erase(boost::signals::detail::named_slot_map::group_iterator&) is
> ambiguous
> libs/signals/src/named_slot_map.cpp:105:23: note: candidates are:
> /usr/include/c++/4.6/bits/stl_map.h:613:7: note: std::map<_Key, _Tp,
> _Compare, _Alloc>::iterator std::map<_Key, _Tp, _Compare,
> _Alloc>::erase(std::map<_Key, _Tp, _Compare, _Alloc>::const_iterator)
> [with _Key = boost::signals::detail::stored_group, _Tp =
> std::list<boost::signals::detail::connection_slot_pair>, _Compare =
> boost::function2<bool, boost::signals::detail::stored_group,
> boost::signals::detail::stored_group>, _Alloc =
> std::allocator<std::pair<const boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >,
> std::map<_Key, _Tp, _Compare, _Alloc>::iterator =
> std::_Rb_tree_iterator<std::pair<const
> boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >,
> std::map<_Key, _Tp, _Compare, _Alloc>::const_iterator =
> std::_Rb_tree_const_iterator<std::pair<const
> boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >]
> /usr/include/c++/4.6/bits/stl_map.h:643:7: note: std::map<_Key, _Tp,
> _Compare, _Alloc>::size_type std::map<_Key, _Tp, _Compare,
> _Alloc>::erase(const key_type&) [with _Key =
> boost::signals::detail::stored_group, _Tp =
> std::list<boost::signals::detail::connection_slot_pair>, _Compare =
> boost::function2<bool, boost::signals::detail::stored_group,
> boost::signals::detail::stored_group>, _Alloc =
> std::allocator<std::pair<const boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >,
> std::map<_Key, _Tp, _Compare, _Alloc>::size_type = long unsigned int,
> std::map<_Key, _Tp, _Compare, _Alloc>::key_type =
> boost::signals::detail::stored_group]
> libs/signals/src/named_slot_map.cpp: In member function void
> boost::signals::detail::named_slot_map::remove_disconnected_slots():
> libs/signals/src/named_slot_map.cpp:128:35: error: call of overloaded
> erase(std::_Rb_tree_iterator<std::pair<const
> boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >::_Self) is
> ambiguous
> libs/signals/src/named_slot_map.cpp:128:35: note: candidates are:
> /usr/include/c++/4.6/bits/stl_map.h:613:7: note: std::map<_Key, _Tp,
> _Compare, _Alloc>::iterator std::map<_Key, _Tp, _Compare,
> _Alloc>::erase(std::map<_Key, _Tp, _Compare, _Alloc>::const_iterator)
> [with _Key = boost::signals::detail::stored_group, _Tp =
> std::list<boost::signals::detail::connection_slot_pair>, _Compare =
> boost::function2<bool, boost::signals::detail::stored_group,
> boost::signals::detail::stored_group>, _Alloc =
> std::allocator<std::pair<const boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >,
> std::map<_Key, _Tp, _Compare, _Alloc>::iterator =
> std::_Rb_tree_iterator<std::pair<const
> boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >,
> std::map<_Key, _Tp, _Compare, _Alloc>::const_iterator =
> std::_Rb_tree_const_iterator<std::pair<const
> boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >]
> /usr/include/c++/4.6/bits/stl_map.h:643:7: note: std::map<_Key, _Tp,
> _Compare, _Alloc>::size_type std::map<_Key, _Tp, _Compare,
> _Alloc>::erase(const key_type&) [with _Key =
> boost::signals::detail::stored_group, _Tp =
> std::list<boost::signals::detail::connection_slot_pair>, _Compare =
> boost::function2<bool, boost::signals::detail::stored_group,
> boost::signals::detail::stored_group>, _Alloc =
> std::allocator<std::pair<const boost::signals::detail::stored_group,
> std::list<boost::signals::detail::connection_slot_pair> > >,
> std::map<_Key, _Tp, _Compare, _Alloc>::size_type = long unsigned int,
> std::map<_Key, _Tp, _Compare, _Alloc>::key_type =
> boost::signals::detail::stored_group]
>
> On 08/10/2011 06:27 AM, TONGARI wrote:
>
>
>
>
>
>
>
>
>
> > 2011/8/10 rudy b<rudyke..._at_[hidden]>
>
> >> Hi,
> >> I am newb in using boost. And, I am having so much trouble installing
> >> and running a simple example. I would REALLY appreciate some help.
>
> >> I tried to install boost_1_47_0.tar.gz on my unix machine, and I
> >> followed the stpes
>
> >>http://www.boost.org/doc/libs/1_47_0/more/getting_started/unix-varian...
>
> >> to first build, and install the libraries.
>
> >> I had no problem running some the examples (provided on the link
> >> above, that was using some of its already built libraries), and they
> >> all worked.
>
> >> The problem is when I try to run an example that is using a
> >> boost_filesystem.
>
> >> I tried uninstalling/installing different boost versions, cause I
> >> thought the error may be version dependent, but it wasn't.
> >> I also tried to built the entire library using different versions of
> >> gcc (3.4.6, 4.3.5, 4.4.0, 4.5.0, 4.5.1, 4.5.2, 4.6.0), and I get the
> >> same error messages.
> >> I even made sure that when compile, I have the boost_1_4x_0 path in my
> >> compile script. I also made sure that I have appended boost_1_4x_0
> >> path to my $path.
>
> >> I even tried to have -lboost_filesystem in my compile script, but this
> >> didn't help either !!!
>
> >> This is the type of error that I am getting:
>
> >> /tmp/cczDoDOU.o: In function
> >> `__static_initialization_and_destruction_0(int, int)':
> >> sync.cpp:(.text+0xe03): undefined reference to
> >> `boost::system::generic_category()'
> >> sync.cpp:(.text+0xe1e): undefined reference to
> >> `boost::system::generic_category()'
> >> sync.cpp:(.text+0xe39): undefined reference to
> >> `boost::system::system_category()'
> >> /tmp/cczDoDOU.o: In function
> >> `boost::filesystem3::last_write_time(boost::filesystem3::path const&,
> >> long)':
>
> > Try to link Boost.System (e.g. -lboost_system) as well.
>
> > _______________________________________________
> > Boost-users mailing list
> > Boost-us..._at_[hidden]
> >http://lists.boost.org/mailman/listinfo.cgi/boost-users
>
> --
> Claas H. Köhler
>
> Deutsches Zentrum für Luft- und Raumfahrt e.V. (DLR)
> in der Helmholtz-Gemeinschaft
>
> Institut für Methodik der Fernerkundung (IMF-AP)
> Earth Observation Center (EOC)
>
> Münchner Str
> 82234 Weßling
> Germany
>
> Telefon +49 8153 28-1274
> Telefax +49 8153 28-1446
>
> E-Mail claas.koeh..._at_[hidden]
> Internethttp://www.dlr.de
> _______________________________________________
> Boost-users mailing list
> Boost-us..._at_[hidden]http://lists.boost.org/mailman/listinfo.cgi/boost-users
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