Przeglądaj źródła

kconfig: fix localmodconfig

When kconfig syntax moved to use $(FOO) for environment variables
localmodconfig was not updated.
Fix so it now works with the new syntax $(FOO)

Fixes: 104daea149c4 ("kconfig: reference environment variables directly and remove 'option env='")
Reported-by: Kevin Locke <kevin@kevinlocke.name>
Reported-by: Andrei Vagin <avagin@virtuozzo.com>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Tested-by: Kevin Locke <kevin@kevinlocke.name>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Sam Ravnborg 7 lat temu
rodzic
commit
8593080c0f
1 zmienionych plików z 2 dodań i 2 usunięć
  1. 2 2
      scripts/kconfig/streamline_config.pl

+ 2 - 2
scripts/kconfig/streamline_config.pl

@@ -165,10 +165,10 @@ sub read_kconfig {
     my $last_source = "";
 
     # Check for any environment variables used
-    while ($source =~ /\$(\w+)/ && $last_source ne $source) {
+    while ($source =~ /\$\((\w+)\)/ && $last_source ne $source) {
 	my $env = $1;
 	$last_source = $source;
-	$source =~ s/\$$env/$ENV{$env}/;
+	$source =~ s/\$\($env\)/$ENV{$env}/;
     }
 
     open(my $kinfile, '<', $source) || die "Can't open $kconfig";