Problem in using Transitive_closure on Linux
Hi.. I m able to run transitive_closure on my windows machine but the same program gives me the following error on Linux machine what can be the reason for this .. /usr/include/boost/graph/depth_first_search.hpp: In function âvoid boost::depth_first_search(const VertexListGraph&, const boost::bgl_named_params<P, T, R>&) [with VertexListGraph = std::vector<std::vector<long unsigned int, std::allocator<long unsigned int> >, std::allocator<std::vector<long unsigned int, std::allocator<long unsigned int> > > >, P = boost::topo_sort_visitor<std::back_insert_iterator<std::vector<long unsigned int, std::allocator<long unsigned int> > > >, T = boost::graph_visitor_t, R = boost::bgl_named_params<boost::identity_property_map, boost::vertex_index_t, boost::no_property>]â: /usr/include/boost/graph/topological_sort.hpp:64: instantiated from âvoid boost::topological_sort(VertexListGraph&, OutputIterator, const boost::bgl_named_params<P, T, R>&) [with VertexListGraph = std::vector<std::vector<long unsigned int, std::allocator<long unsigned int> >, std::allocator<std::vector<long unsigned int, std::allocator<long unsigned int> > > >, OutputIterator = std::back_insert_iterator<std::vector<long unsigned int, std::allocator<long unsigned int> > >, P = boost::identity_property_map, T = boost::vertex_index_t, R = boost::no_property]â /usr/include/boost/graph/transitive_closure.hpp:120: instantiated from âvoid boost::transitive_closure(const Graph&, GraphTC&, G_to_TC_VertexMap, VertexIndexMap) [with Graph = boost::adjacency_list<boost::setS, boost::vecS, boost::bidirectionalS, boost::property<boost::vertex_name_t, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, boost::no_property>, boost::property<boost::edge_weight_t, int, boost::no_property>, boost::no_property, boost::listS>, GraphTC = boost::adjacency_list<boost::setS, boost::vecS, boost::bidirectionalS, boost::property<boost::vertex_name_t, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, boost::no_property>, boost::property<boost::edge_weight_t, int, boost::no_property>, boost::no_property, boost::listS>, G_to_TC_VertexMap = boost::iterator_property_map<long unsigned int*, boost::vec_adj_list_vertex_id_map<boost::property<boost::vertex_name_t, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, boost::no_property>, long unsigned int>, long unsigned int, long unsigned int&>, VertexIndexMap = boost::vec_adj_list_vertex_id_map<boost::property<boost::vertex_name_t, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, boost::no_property>, long unsigned int>]â /usr/include/boost/graph/transitive_closure.hpp:263: instantiated from âvoid boost::transitive_closure(const Graph&, GraphTC&) [with Graph = Graph, GraphTC = Graph]â sample_main.cpp:121: instantiated from here /usr/include/boost/graph/depth_first_search.hpp:324: error: no matching function for call to âvertices(const std::vector<std::vector<long unsigned int, std::allocator<long unsigned int> >, std::allocator<std::vector<long unsigned int, std::allocator<long unsigned int> > > >&)â //Pseudo Code on which it is failing /... Graph TC; transitive_closure(Original_graph, TC); ...// Kindly help..... Thanks Abhishek Vyas Tata Consultancy Services Mailto: abhishek.v@tcs.com Website: http://www.tcs.com ____________________________________________ Experience certainty. IT Services Business Solutions Outsourcing ____________________________________________ =====-----=====-----===== Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you
On Nov 19, 2007 7:15 AM, <abhishek.v@tcs.com> wrote:
Hi.. I m able to run transitive_closure on my windows machine but the same program gives me the following error on Linux machine what can be the reason for this ..
<snip>
/usr/include/boost/graph/depth_first_search.hpp:324: error: no matching function for call to âvertices(const std::vector<std::vector<long unsigned int, std::allocator<long unsigned int> >, std::allocator<std::vector<long unsigned int, std::allocator<long unsigned int> > > >&)â
//Pseudo Code on which it is failing /... Graph TC; transitive_closure(Original_graph, TC); ...//
From the error messages you've included, I'm assuming you're using gcc version 4.1.x or above, and that you're compiling code very similar to
Hi Abhishek, the file libs/graph/test/transitive_closure_test.cpp? If so, try removing the #include of depth_first_search.hpp at the top of the file, or at least moving the #include of vector_as_graph.hpp before it as a workaround. Regards, Aaron
Hi Aaron.. You are right i'm using gcc version 4.2.1 and also after including vector_as_graph.hpp the program is running fine . But what is the reason of including this header file. Thanks Abhishek boost-users-bounces@lists.boost.org wrote on 11/19/2007 07:36:43 PM:
On Nov 19, 2007 7:15 AM, <abhishek.v@tcs.com> wrote:
Hi.. I m able to run transitive_closure on my windows machine but the same program gives me the following error on Linux machine what can be the reason for this ..
<snip>
/usr/include/boost/graph/depth_first_search.hpp:324: error: no matching function for call to âvertices(const std::vector<std::vector<long unsigned int, std::allocator<long unsigned int> >, std::allocator<std::vector<long unsigned int, std::allocator<long unsigned int> > > >&)â
//Pseudo Code on which it is failing /... Graph TC; transitive_closure(Original_graph, TC); ...//
Hi Abhishek,
From the error messages you've included, I'm assuming you're using gcc version 4.1.x or above, and that you're compiling code very similar to the file libs/graph/test/transitive_closure_test.cpp? If so, try removing the #include of depth_first_search.hpp at the top of the file, or at least moving the #include of vector_as_graph.hpp before it as a workaround.
Regards, Aaron _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
ForwardSourceID:NT0004C3C6 =====-----=====-----===== Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you
On Nov 19, 2007 10:54 PM, <abhishek.v@tcs.com> wrote:
Hi Aaron..
You are right i'm using gcc version 4.2.1 and also after including vector_as_graph.hpp the program is running fine . But what is the reason of including this header file.
Thanks Abhishek boost-users-bounces@lists.boost.org wrote on 11/19/2007 07:36:43 PM:
I wish I knew - gcc is getting confused when depth_first_search.hpp is included first. It's a workaround, until someone can figure out whether the problem is with the code or gcc. Aaron
participants (2)
-
Aaron Windsor
-
abhishek.v@tcs.com