41static char *
useString =
"Usage: %s [-vr?] <files>\n\
42 -o FILE - redirect output (default to stdout)\n\
43 -v - verbose (to stderr)\n\
44 -r - print removed edges to stderr\n\
46If no files are specified, stdin is used\n";
59 while ((c = getopt(argc, argv,
"o:vr?")) != -1) {
62 (void)fclose(
opts->out);
63 opts->out = fopen(optarg,
"w");
65 fprintf(stderr,
"cannot open %s for writing\n",
74 opts->PrintRemovedEdges =
true;
77 if (optopt ==
'\0' || optopt ==
'?')
80 fprintf(stderr,
"%s: option -%c unrecognized\n",
96int main(
int argc,
char **argv)
abstract graph C library, Cgraph API
static NORETURN void graphviz_exit(int status)
void graphviz_tred(Agraph_t *g, const graphviz_tred_options_t *opts)
programmatic access to tred - transitive reduction
int agisdirected(Agraph_t *g)
int agclose(Agraph_t *g)
deletes a graph, freeing its associated storage
static const char * usage
Agraph_t * nextGraph(ingraph_state *sp)
ingraph_state * newIngraph(ingraph_state *sp, char **files)
supports user-supplied data
options for passing to graphviz_tred