kconfig: small code refactoring in kconfig Makefile
Do not hardcode the arch/$(ARCH)/Kconfig name all over Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
This commit is contained in:
parent
d013a27cb7
commit
e703f75d62
|
@ -4,23 +4,25 @@
|
||||||
|
|
||||||
PHONY += oldconfig xconfig gconfig menuconfig config silentoldconfig update-po-config
|
PHONY += oldconfig xconfig gconfig menuconfig config silentoldconfig update-po-config
|
||||||
|
|
||||||
|
Kconfig := arch/$(ARCH)/Kconfig
|
||||||
|
|
||||||
xconfig: $(obj)/qconf
|
xconfig: $(obj)/qconf
|
||||||
$< arch/$(ARCH)/Kconfig
|
$< $(Kconfig)
|
||||||
|
|
||||||
gconfig: $(obj)/gconf
|
gconfig: $(obj)/gconf
|
||||||
$< arch/$(ARCH)/Kconfig
|
$< $(Kconfig)
|
||||||
|
|
||||||
menuconfig: $(obj)/mconf
|
menuconfig: $(obj)/mconf
|
||||||
$< arch/$(ARCH)/Kconfig
|
$< $(Kconfig)
|
||||||
|
|
||||||
config: $(obj)/conf
|
config: $(obj)/conf
|
||||||
$< arch/$(ARCH)/Kconfig
|
$< $(Kconfig)
|
||||||
|
|
||||||
oldconfig: $(obj)/conf
|
oldconfig: $(obj)/conf
|
||||||
$< -o arch/$(ARCH)/Kconfig
|
$< -o $(Kconfig)
|
||||||
|
|
||||||
silentoldconfig: $(obj)/conf
|
silentoldconfig: $(obj)/conf
|
||||||
$< -s arch/$(ARCH)/Kconfig
|
$< -s $(Kconfig)
|
||||||
|
|
||||||
# Create new linux.po file
|
# Create new linux.po file
|
||||||
# Adjust charset to UTF-8 in .po file to accept UTF-8 in Kconfig files
|
# Adjust charset to UTF-8 in .po file to accept UTF-8 in Kconfig files
|
||||||
|
@ -45,27 +47,27 @@ update-po-config: $(obj)/kxgettext
|
||||||
PHONY += randconfig allyesconfig allnoconfig allmodconfig defconfig
|
PHONY += randconfig allyesconfig allnoconfig allmodconfig defconfig
|
||||||
|
|
||||||
randconfig: $(obj)/conf
|
randconfig: $(obj)/conf
|
||||||
$< -r arch/$(ARCH)/Kconfig
|
$< -r $(Kconfig)
|
||||||
|
|
||||||
allyesconfig: $(obj)/conf
|
allyesconfig: $(obj)/conf
|
||||||
$< -y arch/$(ARCH)/Kconfig
|
$< -y $(Kconfig)
|
||||||
|
|
||||||
allnoconfig: $(obj)/conf
|
allnoconfig: $(obj)/conf
|
||||||
$< -n arch/$(ARCH)/Kconfig
|
$< -n $(Kconfig)
|
||||||
|
|
||||||
allmodconfig: $(obj)/conf
|
allmodconfig: $(obj)/conf
|
||||||
$< -m arch/$(ARCH)/Kconfig
|
$< -m $(Kconfig)
|
||||||
|
|
||||||
defconfig: $(obj)/conf
|
defconfig: $(obj)/conf
|
||||||
ifeq ($(KBUILD_DEFCONFIG),)
|
ifeq ($(KBUILD_DEFCONFIG),)
|
||||||
$< -d arch/$(ARCH)/Kconfig
|
$< -d $(Kconfig)
|
||||||
else
|
else
|
||||||
@echo "*** Default configuration is based on '$(KBUILD_DEFCONFIG)'"
|
@echo "*** Default configuration is based on '$(KBUILD_DEFCONFIG)'"
|
||||||
$(Q)$< -D arch/$(SRCARCH)/configs/$(KBUILD_DEFCONFIG) arch/$(ARCH)/Kconfig
|
$(Q)$< -D arch/$(SRCARCH)/configs/$(KBUILD_DEFCONFIG) $(Kconfig)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
%_defconfig: $(obj)/conf
|
%_defconfig: $(obj)/conf
|
||||||
$(Q)$< -D arch/$(SRCARCH)/configs/$@ arch/$(ARCH)/Kconfig
|
$(Q)$< -D arch/$(SRCARCH)/configs/$@ $(Kconfig)
|
||||||
|
|
||||||
# Help text used by make help
|
# Help text used by make help
|
||||||
help:
|
help:
|
||||||
|
|
Loading…
Reference in a new issue