Improve compatibility of graphviz image example to fix build problems.