mirror of
https://github.com/radareorg/radare2.git
synced 2024-11-27 23:20:40 +00:00
f88fd507cd
* Initial import of depgraph.pl helper script to get the libr internal library dependencies graph with graphviz
16 lines
311 B
Bash
16 lines
311 B
Bash
#!/bin/sh
|
|
#
|
|
# Usage : perl depgraph.pl | dot -Tpng /dev/stdin > deps.png
|
|
#
|
|
grep -e DEPS */Makefile |sed -e 's,/Makefile,,' > /tmp/rdeps.txt
|
|
|
|
echo "digraph G {";
|
|
cat /tmp/rdeps.txt | perl -ne '
|
|
/(.*):(.*)=(.*)$/;
|
|
my $lib=$1;
|
|
@deps=split(/ /, $3);
|
|
foreach $dep (@deps) {
|
|
print " $dep -> r_$lib;\n";
|
|
}';
|
|
echo "}";
|