summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorBjörn Stenberg <bjorn@haxx.se>2008-11-22 23:04:15 +0000
committerBjörn Stenberg <bjorn@haxx.se>2008-11-22 23:04:15 +0000
commit40d95f457428ba9118f55ec8d901df5bf14ef8b6 (patch)
treeca37d025efae6ccc5991727fddacf91016e0541b /tools
parent9701ffbe23cf6e2a076ed0afb2345cbb0adc471f (diff)
downloadrockbox-40d95f457428ba9118f55ec8d901df5bf14ef8b6.tar.gz
rockbox-40d95f457428ba9118f55ec8d901df5bf14ef8b6.tar.bz2
rockbox-40d95f457428ba9118f55ec8d901df5bf14ef8b6.zip
Support split target.o:source.c lines.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19184 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'tools')
-rwxr-xr-xtools/addtargetdir.pl15
1 files changed, 15 insertions, 0 deletions
diff --git a/tools/addtargetdir.pl b/tools/addtargetdir.pl
index 37a2b6630e..abc6526dd7 100755
--- a/tools/addtargetdir.pl
+++ b/tools/addtargetdir.pl
@@ -15,6 +15,8 @@ use File::Basename;
my $rbroot = $ARGV[0];
my $builddir = $ARGV[1];
+my $target2;
+
for (<STDIN>) {
if (/^([^:]+): (\S+) (.*)/) {
my ($target, $src, $rest) = ($1, $2, $3);
@@ -22,6 +24,19 @@ for (<STDIN>) {
$dir =~ s/$rbroot//;
print "$builddir$dir/$target: $src $rest\n";
}
+ elsif (/^([^:]+): \\/) {
+ # target and source on different lines
+ $target2 = $1;
+ }
+ elsif ($target2) {
+ if (/^\s+([^ ]+) (.*)/) {
+ my ($src, $rest) = ($1, $2);
+ my $dir = dirname $src;
+ $dir =~ s/$rbroot//;
+ print "$builddir$dir/$target2: $src $rest\n";
+ $target2 = "";
+ }
+ }
else {
print $_;
}