diff options
-rw-r--r-- | tools/linktrace-to-depfile.pl | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/tools/linktrace-to-depfile.pl b/tools/linktrace-to-depfile.pl new file mode 100644 index 000000000..8607baa1e --- /dev/null +++ b/tools/linktrace-to-depfile.pl @@ -0,0 +1,18 @@ +#!/usr/bin/perl -w + +use strict; +use Cwd qw(abs_path); + +my %deps; + +while (my $line = <>) { + chomp $line; + if ($line =~ /\(([^)]+)/) { + $deps{abs_path($1)} = 1; + } +} + +my @deps = keys %deps; + +print join("\t\\\n\t", @deps), "\n"; + |