kernel generate-config.pl: Allow whitespace in values

In particular, this allows setting CONFIG_CMDLINE to a value with
multiple space-seperated parameters. Other variables also take free-form
strings and might similarly benefit.
This commit is contained in:
Eric Culp 2019-08-11 14:01:51 -07:00
parent d98a165de7
commit 92cc949f9f

View File

@ -28,7 +28,7 @@ open ANSWERS, "<$ENV{KERNEL_CONFIG}" or die "Could not open answer file";
while (<ANSWERS>) {
chomp;
s/#.*//;
if (/^\s*([A-Za-z0-9_]+)(\?)?\s+(\S+)\s*$/) {
if (/^\s*([A-Za-z0-9_]+)(\?)?\s+(.*\S)\s*$/) {
$answers{$1} = $3;
$requiredAnswers{$1} = !(defined $2);
} elsif (!/^\s*$/) {