summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xv4l/scripts/analyze_build.pl8
1 files changed, 7 insertions, 1 deletions
diff --git a/v4l/scripts/analyze_build.pl b/v4l/scripts/analyze_build.pl
index 945377fa4..9a291a2e3 100755
--- a/v4l/scripts/analyze_build.pl
+++ b/v4l/scripts/analyze_build.pl
@@ -97,9 +97,15 @@ sub open_makefile($) {
next;
}
if (/(\S+)-objs\s*([:+]?)=\s*(\S.*?)\s*$/) {
- print STDERR "Should use ':=' in $file:$.\n$_\n" if ($check && $2 ne ':');
my @files = split(/\s+/, $3);
map { s|^(.*)\.o$|$dir/\1| } @files;
+ if ($2 eq '+') {
+ # Adding to files
+ print STDERR "Should use ':=' in $file:$.\n$_\n" if ($check && !exists $multi{"$dir/$1"});
+ push @files, @{$multi{"$dir/$1"}};
+ } else {
+ print STDERR "Setting objects twice in $file:$.\n$_\n" if ($check && exists $multi{"$dir/$1"});
+ }
$multi{"$dir/$1"} = \@files;
next;
}