mirror of
https://github.com/linuxboot/heads.git
synced 2024-12-20 21:43:11 +00:00
single line output for tracking which libraries go with which programs
This commit is contained in:
parent
be725ed104
commit
b27aebc559
@ -11,6 +11,7 @@ my $dest = shift
|
|||||||
or die "Usage: $0 dest-dir [programs...]\n";
|
or die "Usage: $0 dest-dir [programs...]\n";
|
||||||
|
|
||||||
my %libraries;
|
my %libraries;
|
||||||
|
my %deps;
|
||||||
|
|
||||||
for my $file (@ARGV)
|
for my $file (@ARGV)
|
||||||
{
|
{
|
||||||
@ -30,6 +31,7 @@ for my $file (@ARGV)
|
|||||||
{
|
{
|
||||||
# Normal library
|
# Normal library
|
||||||
$libraries{$1}++;
|
$libraries{$1}++;
|
||||||
|
push @{$deps{$file}}, $1;
|
||||||
}
|
}
|
||||||
elsif (/^\s+([^ ]+) \(/)
|
elsif (/^\s+([^ ]+) \(/)
|
||||||
{
|
{
|
||||||
@ -40,6 +42,11 @@ for my $file (@ARGV)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#print Dumper(\%libraries);
|
#print Dumper(\%libraries);
|
||||||
|
print "$_: ", join(" ", @{$deps{$_}}), "\n"
|
||||||
|
for keys %deps;
|
||||||
|
|
||||||
|
print "\n";
|
||||||
|
|
||||||
|
|
||||||
unless( -d $dest )
|
unless( -d $dest )
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user