[PATCH] media-build: fix menuconfig usage for kernel >= 5.13.0

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Tomasz Maciej Nowak <tmn505@xxxxxxxxx>

Because of 6dd85ff178cd ("kconfig: change "modules" from sub-option to
first-level attribute") in Linux kernel the "option" key-word is not
recognised anymore. That causes an abort when menuconfig is invoked.
Fix it by adding proper attribute depending on kernel version the
media_build is used against.

Signed-off-by: Tomasz Maciej Nowak <tmn505@xxxxxxxxx>
---
 v4l/scripts/make_kconfig.pl | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/v4l/scripts/make_kconfig.pl b/v4l/scripts/make_kconfig.pl
index 69f0c67a37b1..76fbf8a168bc 100755
--- a/v4l/scripts/make_kconfig.pl
+++ b/v4l/scripts/make_kconfig.pl
@@ -651,7 +651,11 @@ while (my ($key, $deps) = each %depend) {
 	print OUT "# Needed by ", join(', ', keys %$deps), "\n";
 	print OUT "config $key\n\ttristate\n";
 	print OUT "\tdefault ", qw(n m y)[$kernopts{$key}], "\n\n";
-	print OUT "\toption modules\n" if ($key eq "MODULES");
+	if (cmp_ver($kernver, '5.13.0') < 0) {
+		print OUT "\toption modules\n" if ($key eq "MODULES");
+	} else {
+		print OUT "\tmodules\n" if ($key eq "MODULES");
+	}
 }
 close OUT;
 
-- 
2.38.1




[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux