Visualizing rpm dependencies with Graphviz

Sometimes, rpm dependencies get rather complex. It’s not always easy for an rpm maintainer to keep track of the runtime requirements of his package and therefore, huge rpm dependency trees develop. And it’s even more difficult so see which packages get pulled by yum, because only a tiny part of those are actually listed as requirements in the spec file. The tree gets huge with recursion!

With rpmdep, there’s a small tool that will help you visualize those dependency trees. It’s part of Fedora’s rpmorphan-package, so you can easily pull it with yum:

# yum install rpmorphan

rpmdep itself is just a perl script, that walks down the rpm tree recursively. It can produce a Graphviz dot-file, which in turn can be used to make rather since pictures. For example,

$ rpmdep -dot firefox
$ dot -Tpng -o firefox.png

produces a complete rpm dependency tree for firefox. An exemplary picture (firefox’s dependencies in Fedora 13):

Click image for full size (1.6MB)

Graphvic can produce quite a few output formats. For an overview about all available commands, have a look at

3 thoughts on “Visualizing rpm dependencies with Graphviz

  1. avatarRichard Raseley

    Thank you for this post – very helpful.

    One note – the two most recent versions of rpmdep seem to be broken, so I had to go back to the package from late 2010.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.