kconfig: fix localmodconfig
PATCH 1/1 kconfig: fix localmodconfig
From 47857284fd19ef953e3beb7338154924a74b62d2 Mon Sep 17 00:00:00 2001
From: Sam Ravnborg <[email protected]>
Date: Fri, 8 Jun 2018 23:48:31 +0200
Subject: [PATCH 1/1] 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)
--- scripts/kconfig/streamline_config.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
scripts/kconfig/streamline_config.pl +2 -2
@@ -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";
Signature · 1 line
2.12.0
Quoted 5 lines · Sam Ravnborg
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 104daea149c45cc84842ce77a9bd6436d19f3dd8 ("kconfig: reference environment variables directly and remove 'option env='")
I can confirm make localmodconfig from 104daea149c4 with this patch applied creates the same .config as it did in 104daea149c4^ and that it creates a plausible .config (which I haven't built/tested yet) when applied to master.
Works for me. Thanks for the very fast fix!
Cheers,
Kevin
2018-06-09 6:53 GMT+09:00 Sam Ravnborg <[email protected]>:
Quoted 9 lines
From
47857284fd19ef953e3beb7338154924a74b62d2Mon Sep 17 00:00:00 2001
From: Sam Ravnborg <[email protected]>
Date: Fri, 8 Jun 2018 23:48:31 +0200
Subject: [PATCH 1/1] kconfig: fix localmodconfigWhen kconfig syntax moved to use $(FOO) for environment variables localmodconfig was not updated.
Fix so it now works with the new syntax $(FOO)
Quoted 5 lines
Fixes 104daea149c45cc84842ce77a9bd6436d19f3dd8 ("kconfig: reference environment variables directly and remove 'option env='")Reported-by Kevin Locke <[email protected]>Reported-by Andrei Vagin <[email protected]>Signed-off-by Sam Ravnborg <[email protected]>---
Applied to linux-kbuild. Thanks!
Quoted 27 lines
scripts/kconfig/streamline_config.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)scripts/kconfig/streamline_config.pl +2
-3@@ -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"; --2.12.0
--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 2 lines
Best Regards Masahiro Yamada