pmaports-a71/device/.shared-patches/linux/fix-check-lxdialog-makefile.patch
Masanori Ogino 0b0eb5a3f7
linux: add two quirks for check-lxdialog.sh (MR 5516)
This change adds patches for fixing `make menuconfig` failures with old
kernels due to changes in GNU Make and C compilers.

Signed-off-by: Masanori Ogino <mogino@acm.org>
[ci:skip-build]: already built successfully in CI
2024-09-03 22:56:29 -07:00

26 lines
1.1 KiB
Diff

It seems that newer versions of GNU Make do not allow to use variables before
defining it.
diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile
index 844bc9da..911c6ba1 100644
--- a/scripts/kconfig/Makefile
+++ b/scripts/kconfig/Makefile
@@ -192,6 +192,8 @@ clean-files += zconf.tab.c zconf.lex.c zconf.hash.c gconf.glade.h
clean-files += mconf qconf gconf nconf
clean-files += config.pot linux.pot
+HOSTLOADLIBES_mconf = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ldflags $(HOSTCC))
+
# Check that we have the required ncurses stuff installed for lxdialog (menuconfig)
PHONY += $(obj)/dochecklxdialog
$(addprefix $(obj)/,$(lxdialog)): $(obj)/dochecklxdialog
@@ -217,8 +219,6 @@ HOSTLOADLIBES_gconf = `pkg-config --libs gtk+-2.0 gmodule-2.0 libglade-2.0`
HOSTCFLAGS_gconf.o = `pkg-config --cflags gtk+-2.0 gmodule-2.0 libglade-2.0` \
-Wno-missing-prototypes
-HOSTLOADLIBES_mconf = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ldflags $(HOSTCC))
-
HOSTLOADLIBES_nconf = $(shell \
pkg-config --libs menu panel ncurses 2>/dev/null \
|| echo "-lmenu -lpanel -lncurses" )