Build changes for Linux kconfig code to work in seabios dir structure.
diff --git a/Makefile b/Makefile
index 384bf79..c7dfc0b 100644
--- a/Makefile
+++ b/Makefile
@@ -54,13 +54,14 @@
 Q=
 else
 Q=@
+MAKEFLAGS += --no-print-directory
 endif
 
 OBJCOPY=objcopy
 OBJDUMP=objdump
 STRIP=strip
 
-.PHONY : all FORCE
+.PHONY : all clean distclean FORCE
 
 vpath %.c src vgasrc
 vpath %.S src vgasrc
@@ -193,10 +194,24 @@
 
 $(OUT)ccode32flat.o: src/acpi-dsdt.hex
 
+####### Kconfig rules
+export HOSTCC             := $(CC)
+export CONFIG_SHELL       := sh
+export KCONFIG_AUTOHEADER := autoconf.h
+export KCONFIG_CONFIG     := $(CURDIR)/.config
+
+%onfig:
+	$(Q)mkdir -p $(OUT)/tools/kconfig/lxdialog
+	$(Q)mkdir -p $(OUT)/include/config
+	$(Q)$(MAKE) -C $(OUT) -f $(CURDIR)/tools/kconfig/Makefile srctree=$(CURDIR) src=tools/kconfig obj=tools/kconfig Q=$(Q) Kconfig=$(CURDIR)/src/Kconfig $@
+
 ####### Generic rules
 clean:
 	$(Q)rm -rf $(OUT)
 
+distclean: clean
+	$(Q)rm -f .config .config.old
+
 $(OUT):
 	$(Q)mkdir $@