3 # Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
11 # addtargetdir.pl - Adds target directory to gcc-generated dependency data
15 my $rbroot = $ARGV[0];
16 my $builddir = $ARGV[1];
21 if (/^([^:]+): (\S+) (.*)/) {
22 my ($target, $src, $rest) = ($1, $2, $3);
23 my $dir = dirname
$src;
24 $dir =~ s/^.*$rbroot//;
25 print "$builddir$dir/$target: $src $rest\n";
27 elsif (/^([^:]+): \\/) {
28 # target and source on different lines
32 if (/^\s+([^ ]+) (.*)/) {
33 my ($src, $rest) = ($1, $2);
34 my $dir = dirname
$src;
35 $dir =~ s/^.*$rbroot//;
36 print "$builddir$dir/$target2: $src $rest\n";