my @hex_locations = (\"$FindBin::Bin/../../../project/platform-fsm9900_cdp-full/build-target/gnss-1.0.0\",
\"$FindBin::Bin/../../../project/platform
To answer the actual question.
my @hex_dep_files;
for my $loc (@hex_locations) {
find({
no_chdir => 1,
wanted => sub {
my $F = $File::Find::name;
return if $F !~ /.d$/;
push @hex_dep_files, $F;
},
}, $loc);
}
or
my @hex_dep_files;
find({
no_chdir => 1,
wanted => sub {
my $F = $File::Find::name;
return if $F !~ /.d$/;
push @hex_dep_files, $F;
},
}, @hex_locations);