Visualizing dependencies of kdelibs (or any other cmake-built package)
neundorf at kde.org
Sun Oct 31 17:07:08 GMT 2010
attached you can find a dependency graph for kfile in kdelibs.
This graph was created using dot, and the dotfile has been created
automatically by cmake.
So, you can do this for any cmake-based software, i.e. for all of KDE, etc.
It generates a dot-file for the whole project (too big to be usable e.g. for
kdelibs), and also a separate dot-file for each target.
Some of you may know that cmake has a "--graphviz=<filename>" command line
argument. If you give this to cmake, it will generate a dot file from the
software it is currently generating makefiles for.
Unfortunately this feature is/was a bit buggy.
You need to fetch cmake from the ImprovedDotSupport-branch in git:
Build it, and then you can use it to generate such dependency graphs.
To use it, change into an already existing build tree, and run cmake there:
$ cd builddir/
buildir/$ cmake . --graphviz=kdelibs.dot
-- Generating done
builddir/$ dot kdelibs.dot.kfile -Tpdf -okdelibs.dot.kfile.pdf
And there you have the pdf which is attached here.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 28745 bytes
Desc: not available
More information about the kde-core-devel