mirror of
https://github.com/openwrt/openwrt.git
synced 2025-01-18 10:46:41 +00:00
scripts/package-metadata.pl: strip already selected conditions from dependencies
When a dependency is pulled in via conditional depends, and the condition is already selected earlier in the chain, drop the condition. This avoids some corner cases that trigger recursive dependencies. Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
parent
6252c18d1c
commit
ae88f00357
@ -160,6 +160,8 @@ sub mconf_depends {
|
||||
$depend =~ s/^([@\+]+)// and $flags = $1;
|
||||
my $condition = $parent_condition;
|
||||
|
||||
$depend = $2 if $depend =~ /^(.+):(.+)$/ and $dep->{$1} eq 'select';
|
||||
|
||||
next if $condition eq $depend;
|
||||
next if $seen->{"$parent_condition:$depend"};
|
||||
next if $seen->{":$depend"};
|
||||
|
Loading…
Reference in New Issue
Block a user