Boost logo

Boost Users :

Subject: Re: [Boost-users] [BGL] Trouble linking read_graphviz
From: Michael Olea (oleaj_at_[hidden])
Date: 2009-01-07 15:48:54


On Jan 7, 2009, at 6:55 AM, Andrew Sutton wrote:

> I have been working through the tutorial portion of "The Boost
> Graph Library: User Guide and Reference Manual", and have been
> unable to get example code that includes calls to read_graphviz to
> link. For example, code including this line:
>
> read_graphviz("figs/ospf-graph.dot", g_dot);

<...>

> Any ideas what I'm missing and how I might fix it, or what I need
> to read to find out, would be appreciated.
>
> I remember having similar problems last time I tried to use the
> graphviz stuff. Basically, the "parameter-extracting" version that
> you're calling instantiates a function that doesn't really exist,
> hence the linker error. You have to be more very specific when
> calling read_graphviz. and pass in the istream and a
> dynamic_properties object. I think you can omit the "id" string. I
> think that gave me some problems too.

Turns out the answer I looked at this and yet missed it:

// Deprecated GraphViz readers
void read_graphviz(const std::string& file, GraphvizDigraph& g);
void read_graphviz(FILE* file, GraphvizDigraph& g);
void read_graphviz(const std::string& file, GraphvizGraph& g);
void read_graphviz(FILE* file, GraphvizGraph& g);

http://www.boost.org/doc/libs/1_37_0/libs/graph/doc/read_graphviz.html

Doh! Mystery solved.

-- Michael



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