kconfig/menuconfig: lxdialog is now built-in
authorSam Ravnborg <sam@mars.ravnborg.org>
Thu, 27 Jul 2006 20:10:27 +0000 (22:10 +0200)
committerSam Ravnborg <sam@neptun.ravnborg.org>
Sat, 30 Sep 2006 09:19:19 +0000 (11:19 +0200)
lxdialog was previously called as an external program causing screen
to flicker when used. With this patch lxdialog is now built-in.
It is loosly based om previous work by:  Petr Baudis <pasky@ucw.cz>

Following is a list of changes:
o Moved build of dialog routings to kconfig Makefile
o menubox + checklist uses a new item list to hold all menu items
o in util.c implmented helper function to deal with item list
o menubox now uses parameters to save scroll state (avoids temp file)
o textbox now get text to be displayed as parameter and not a file
o make sure to properly delete subwin's before main windows
o killed unused files: lxdialog.c msgbox.c
o modified return value for ESC to match direct calling
o in a few places the code has been adjusted to 80 char wide
o in textbox a small refactoring was made to make code remotely readable
o in mconf removed all unused stuff (functions/variables)

Following is a list of know short comings:
a) pressing ESC twice will be interpreted as two ESC presses
b) resize does not work. menuconfig needs to be restarted to be adjusted

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
12 files changed:
scripts/kconfig/Makefile
scripts/kconfig/lxdialog/Makefile [deleted file]
scripts/kconfig/lxdialog/checklist.c
scripts/kconfig/lxdialog/dialog.h
scripts/kconfig/lxdialog/inputbox.c
scripts/kconfig/lxdialog/lxdialog.c [deleted file]
scripts/kconfig/lxdialog/menubox.c
scripts/kconfig/lxdialog/msgbox.c [deleted file]
scripts/kconfig/lxdialog/textbox.c
scripts/kconfig/lxdialog/util.c
scripts/kconfig/lxdialog/yesno.c
scripts/kconfig/mconf.c

index a90d3cc..b2928f0 100644 (file)
@@ -11,7 +11,6 @@ gconfig: $(obj)/gconf
        $< arch/$(ARCH)/Kconfig
 
 menuconfig: $(obj)/mconf
-       $(Q)$(MAKE) $(build)=scripts/kconfig/lxdialog
        $< arch/$(ARCH)/Kconfig
 
 config: $(obj)/conf
@@ -81,6 +80,23 @@ help:
        @echo  '  allyesconfig    - New config where all options are accepted with yes'
        @echo  '  allnoconfig     - New config where all options are answered with no'
 
+# lxdialog stuff
+check-lxdialog  := $(srctree)/$(src)/lxdialog/check-lxdialog.sh
+
+# Use reursively expanded variables so we do not call gcc unless
+# we really need to do so. (Do not call gcc as part of make mrproper)
+HOST_EXTRACFLAGS = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags)
+HOST_LOADLIBES   = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ldflags $(HOSTCC))
+
+HOST_EXTRACFLAGS += -DLOCALE
+
+PHONY += $(obj)/dochecklxdialog
+$(obj)/dochecklxdialog:
+       $(Q)$(CONFIG_SHELL) $(check-lxdialog) -check $(HOSTCC) $(HOST_LOADLIBES)
+
+always := dochecklxdialog
+
+
 # ===========================================================================
 # Shared Makefile for the various kconfig executables:
 # conf:          Used for defconfig, oldconfig and related targets
@@ -92,9 +108,12 @@ help:
 #         Based on GTK which needs to be installed to compile it
 # object files used by all kconfig flavours
 
+lxdialog := lxdialog/checklist.o lxdialog/util.o lxdialog/inputbox.o
+lxdialog += lxdialog/textbox.o lxdialog/yesno.o lxdialog/menubox.o
+
 hostprogs-y    := conf mconf qconf gconf kxgettext
 conf-objs      := conf.o  zconf.tab.o
-mconf-objs     := mconf.o zconf.tab.o
+mconf-objs     := mconf.o zconf.tab.o $(lxdialog)
 kxgettext-objs := kxgettext.o zconf.tab.o
 
 ifeq ($(MAKECMDGOALS),xconfig)
diff --cc scripts/kconfig/lxdialog/Makefile
Simple merge
Simple merge
Simple merge
Simple merge
diff --cc scripts/kconfig/lxdialog/lxdialog.c
Simple merge
Simple merge
diff --cc scripts/kconfig/lxdialog/msgbox.c
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge