This will be used to filter out some autogenerated config values from the kernel config files Signed-off-by: Felix Fietkau <[email protected]>
@@ -102,8 +102,15 @@ sub config_sub($$) {
my $cfg1 = shift;
my $cfg2 = shift;
my %config = %{$cfg1};
-
- foreach my $config (keys %$cfg2) {
+ my @keys = map {
+ my $expr = $_;
+ $expr =~ /[?.*]/ ?
+ map {
+ /^$expr$/ ? $_ : ()
+ } keys %config : $expr;
+ } keys %$cfg2;
+
+ foreach my $config (@keys) {
delete $config{$config};
}
return \%config;