Makefile (9714d315d28aef77a097fe905b25cc273c3d72ad) | Makefile (7080e47bb2783c04982526068204c1c8fc2c4c38) |
---|---|
1# =========================================================================== 2# Kernel configuration targets 3# These targets are used from top-level makefile 4 5PHONY += oldconfig xconfig gconfig menuconfig config silentoldconfig update-po-config \ 6 localmodconfig localyesconfig 7 8ifdef KBUILD_KCONFIG --- 7 unchanged lines hidden (view full) --- 16 17gconfig: $(obj)/gconf 18 $< $(Kconfig) 19 20menuconfig: $(obj)/mconf 21 $< $(Kconfig) 22 23config: $(obj)/conf | 1# =========================================================================== 2# Kernel configuration targets 3# These targets are used from top-level makefile 4 5PHONY += oldconfig xconfig gconfig menuconfig config silentoldconfig update-po-config \ 6 localmodconfig localyesconfig 7 8ifdef KBUILD_KCONFIG --- 7 unchanged lines hidden (view full) --- 16 17gconfig: $(obj)/gconf 18 $< $(Kconfig) 19 20menuconfig: $(obj)/mconf 21 $< $(Kconfig) 22 23config: $(obj)/conf |
24 $< $(Kconfig) | 24 $< --oldaskconfig $(Kconfig) |
25 26nconfig: $(obj)/nconf 27 $< $(Kconfig) 28 29oldconfig: $(obj)/conf | 25 26nconfig: $(obj)/nconf 27 $< $(Kconfig) 28 29oldconfig: $(obj)/conf |
30 $< -o $(Kconfig) | 30 $< --$@ $(Kconfig) |
31 32silentoldconfig: $(obj)/conf 33 $(Q)mkdir -p include/generated | 31 32silentoldconfig: $(obj)/conf 33 $(Q)mkdir -p include/generated |
34 $< -s $(Kconfig) | 34 $< --$@ $(Kconfig) |
35 36# if no path is given, then use src directory to find file 37ifdef LSMOD 38LSMOD_F := $(LSMOD) 39ifeq ($(findstring /,$(LSMOD)),) 40 LSMOD_F := $(objtree)/$(LSMOD) 41endif 42endif 43 44localmodconfig: $(obj)/streamline_config.pl $(obj)/conf 45 $(Q)mkdir -p include/generated 46 $(Q)perl $< $(srctree) $(Kconfig) $(LSMOD_F) > .tmp.config | 35 36# if no path is given, then use src directory to find file 37ifdef LSMOD 38LSMOD_F := $(LSMOD) 39ifeq ($(findstring /,$(LSMOD)),) 40 LSMOD_F := $(objtree)/$(LSMOD) 41endif 42endif 43 44localmodconfig: $(obj)/streamline_config.pl $(obj)/conf 45 $(Q)mkdir -p include/generated 46 $(Q)perl $< $(srctree) $(Kconfig) $(LSMOD_F) > .tmp.config |
47 $(Q)if [ -f .config ]; then \ 48 cmp -s .tmp.config .config || \ 49 (mv -f .config .config.old.1; \ 50 mv -f .tmp.config .config; \ 51 $(obj)/conf -s $(Kconfig); \ 52 mv -f .config.old.1 .config.old) \ 53 else \ 54 mv -f .tmp.config .config; \ 55 $(obj)/conf -s $(Kconfig); \ | 47 $(Q)if [ -f .config ]; then \ 48 cmp -s .tmp.config .config || \ 49 (mv -f .config .config.old.1; \ 50 mv -f .tmp.config .config; \ 51 $(obj)/conf --silentoldconfig $(Kconfig); \ 52 mv -f .config.old.1 .config.old) \ 53 else \ 54 mv -f .tmp.config .config; \ 55 $(obj)/conf --silentoldconfig $(Kconfig); \ |
56 fi 57 $(Q)rm -f .tmp.config 58 59localyesconfig: $(obj)/streamline_config.pl $(obj)/conf 60 $(Q)mkdir -p include/generated 61 $(Q)perl $< $(srctree) $(Kconfig) $(LSMOD_F) > .tmp.config 62 $(Q)sed -i s/=m/=y/ .tmp.config | 56 fi 57 $(Q)rm -f .tmp.config 58 59localyesconfig: $(obj)/streamline_config.pl $(obj)/conf 60 $(Q)mkdir -p include/generated 61 $(Q)perl $< $(srctree) $(Kconfig) $(LSMOD_F) > .tmp.config 62 $(Q)sed -i s/=m/=y/ .tmp.config |
63 $(Q)if [ -f .config ]; then \ 64 cmp -s .tmp.config .config || \ 65 (mv -f .config .config.old.1; \ 66 mv -f .tmp.config .config; \ 67 $(obj)/conf -s $(Kconfig); \ 68 mv -f .config.old.1 .config.old) \ 69 else \ 70 mv -f .tmp.config .config; \ 71 $(obj)/conf -s $(Kconfig); \ | 63 $(Q)if [ -f .config ]; then \ 64 cmp -s .tmp.config .config || \ 65 (mv -f .config .config.old.1; \ 66 mv -f .tmp.config .config; \ 67 $(obj)/conf --silentoldconfig $(Kconfig); \ 68 mv -f .config.old.1 .config.old) \ 69 else \ 70 mv -f .tmp.config .config; \ 71 $(obj)/conf --silentoldconfig $(Kconfig); \ |
72 fi 73 $(Q)rm -f .tmp.config 74 75# Create new linux.pot file 76# Adjust charset to UTF-8 in .po file to accept UTF-8 in Kconfig files 77# The symlink is used to repair a deficiency in arch/um 78update-po-config: $(obj)/kxgettext $(obj)/gconf.glade.h 79 $(Q)echo " GEN config" --- 10 unchanged lines hidden (view full) --- 90 $(obj)/kxgettext $$i \ 91 >> $(obj)/config.pot; \ 92 done ) 93 $(Q)msguniq --sort-by-file --to-code=UTF-8 $(obj)/config.pot \ 94 --output $(obj)/linux.pot 95 $(Q)rm -f arch/um/Kconfig.arch 96 $(Q)rm -f $(obj)/config.pot 97 | 72 fi 73 $(Q)rm -f .tmp.config 74 75# Create new linux.pot file 76# Adjust charset to UTF-8 in .po file to accept UTF-8 in Kconfig files 77# The symlink is used to repair a deficiency in arch/um 78update-po-config: $(obj)/kxgettext $(obj)/gconf.glade.h 79 $(Q)echo " GEN config" --- 10 unchanged lines hidden (view full) --- 90 $(obj)/kxgettext $$i \ 91 >> $(obj)/config.pot; \ 92 done ) 93 $(Q)msguniq --sort-by-file --to-code=UTF-8 $(obj)/config.pot \ 94 --output $(obj)/linux.pot 95 $(Q)rm -f arch/um/Kconfig.arch 96 $(Q)rm -f $(obj)/config.pot 97 |
98PHONY += randconfig allyesconfig allnoconfig allmodconfig defconfig | 98PHONY += allnoconfig allyesconfig allmodconfig alldefconfig randconfig |
99 | 99 |
100randconfig: $(obj)/conf 101 $< -r $(Kconfig) | 100allnoconfig allyesconfig allmodconfig alldefconfig randconfig: $(obj)/conf 101 $< --$@ $(Kconfig) |
102 | 102 |
103allyesconfig: $(obj)/conf 104 $< -y $(Kconfig) | 103PHONY += listnewconfig oldnoconfig savedefconfig defconfig |
105 | 104 |
106allnoconfig: $(obj)/conf 107 $< -n $(Kconfig) | 105listnewconfig oldnoconfig: $(obj)/conf 106 $< --$@ $(Kconfig) |
108 | 107 |
109allmodconfig: $(obj)/conf 110 $< -m $(Kconfig) | 108savedefconfig: $(obj)/conf 109 $< --$@=defconfig $(Kconfig) |
111 112defconfig: $(obj)/conf 113ifeq ($(KBUILD_DEFCONFIG),) | 110 111defconfig: $(obj)/conf 112ifeq ($(KBUILD_DEFCONFIG),) |
114 $< -d $(Kconfig) | 113 $< --defconfig $(Kconfig) |
115else 116 @echo "*** Default configuration is based on '$(KBUILD_DEFCONFIG)'" | 114else 115 @echo "*** Default configuration is based on '$(KBUILD_DEFCONFIG)'" |
117 $(Q)$< -D arch/$(SRCARCH)/configs/$(KBUILD_DEFCONFIG) $(Kconfig) | 116 $(Q)$< --defconfig=arch/$(SRCARCH)/configs/$(KBUILD_DEFCONFIG) $(Kconfig) |
118endif 119 120%_defconfig: $(obj)/conf | 117endif 118 119%_defconfig: $(obj)/conf |
121 $(Q)$< -D arch/$(SRCARCH)/configs/$@ $(Kconfig) | 120 $(Q)$< --defconfig=arch/$(SRCARCH)/configs/$@ $(Kconfig) |
122 123# Help text used by make help 124help: 125 @echo ' config - Update current config utilising a line-oriented program' 126 @echo ' nconfig - Update current config utilising a ncurses menu based program' 127 @echo ' menuconfig - Update current config utilising a menu based program' 128 @echo ' xconfig - Update current config utilising a QT based front-end' 129 @echo ' gconfig - Update current config utilising a GTK based front-end' 130 @echo ' oldconfig - Update current config utilising a provided .config as base' 131 @echo ' localmodconfig - Update current config disabling modules not loaded' 132 @echo ' localyesconfig - Update current config converting local mods to core' 133 @echo ' silentoldconfig - Same as oldconfig, but quietly, additionally update deps' | 121 122# Help text used by make help 123help: 124 @echo ' config - Update current config utilising a line-oriented program' 125 @echo ' nconfig - Update current config utilising a ncurses menu based program' 126 @echo ' menuconfig - Update current config utilising a menu based program' 127 @echo ' xconfig - Update current config utilising a QT based front-end' 128 @echo ' gconfig - Update current config utilising a GTK based front-end' 129 @echo ' oldconfig - Update current config utilising a provided .config as base' 130 @echo ' localmodconfig - Update current config disabling modules not loaded' 131 @echo ' localyesconfig - Update current config converting local mods to core' 132 @echo ' silentoldconfig - Same as oldconfig, but quietly, additionally update deps' |
134 @echo ' randconfig - New config with random answer to all options' 135 @echo ' defconfig - New config with default answer to all options' 136 @echo ' allmodconfig - New config selecting modules when possible' 137 @echo ' allyesconfig - New config where all options are accepted with yes' | 133 @echo ' defconfig - New config with default from ARCH supplied defconfig' 134 @echo ' savedefconfig - Save current config as ./defconfig (minimal config)' |
138 @echo ' allnoconfig - New config where all options are answered with no' | 135 @echo ' allnoconfig - New config where all options are answered with no' |
136 @echo ' allyesconfig - New config where all options are accepted with yes' 137 @echo ' allmodconfig - New config selecting modules when possible' 138 @echo ' alldefconfig - New config with all symbols set to default' 139 @echo ' randconfig - New config with random answer to all options' 140 @echo ' listnewconfig - List new options' 141 @echo ' oldnoconfig - Same as silentoldconfig but set new symbols to n (unset)' |
|
139 140# lxdialog stuff 141check-lxdialog := $(srctree)/$(src)/lxdialog/check-lxdialog.sh 142 143# Use recursively expanded variables so we do not call gcc unless 144# we really need to do so. (Do not call gcc as part of make mrproper) 145HOST_EXTRACFLAGS = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) | 142 143# lxdialog stuff 144check-lxdialog := $(srctree)/$(src)/lxdialog/check-lxdialog.sh 145 146# Use recursively expanded variables so we do not call gcc unless 147# we really need to do so. (Do not call gcc as part of make mrproper) 148HOST_EXTRACFLAGS = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) |
146HOST_LOADLIBES = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ldflags $(HOSTCC)) | |
147 148HOST_EXTRACFLAGS += -DLOCALE 149 150 151# =========================================================================== 152# Shared Makefile for the various kconfig executables: 153# conf: Used for defconfig, oldconfig and related targets 154# nconf: Used for the nconfig target. --- 45 unchanged lines hidden (view full) --- 200 .tmp_gtkcheck zconf.tab.c lex.zconf.c zconf.hash.c gconf.glade.h 201clean-files += mconf qconf gconf nconf 202clean-files += config.pot linux.pot 203 204# Check that we have the required ncurses stuff installed for lxdialog (menuconfig) 205PHONY += $(obj)/dochecklxdialog 206$(addprefix $(obj)/,$(lxdialog)): $(obj)/dochecklxdialog 207$(obj)/dochecklxdialog: | 149 150HOST_EXTRACFLAGS += -DLOCALE 151 152 153# =========================================================================== 154# Shared Makefile for the various kconfig executables: 155# conf: Used for defconfig, oldconfig and related targets 156# nconf: Used for the nconfig target. --- 45 unchanged lines hidden (view full) --- 202 .tmp_gtkcheck zconf.tab.c lex.zconf.c zconf.hash.c gconf.glade.h 203clean-files += mconf qconf gconf nconf 204clean-files += config.pot linux.pot 205 206# Check that we have the required ncurses stuff installed for lxdialog (menuconfig) 207PHONY += $(obj)/dochecklxdialog 208$(addprefix $(obj)/,$(lxdialog)): $(obj)/dochecklxdialog 209$(obj)/dochecklxdialog: |
208 $(Q)$(CONFIG_SHELL) $(check-lxdialog) -check $(HOSTCC) $(HOST_EXTRACFLAGS) $(HOST_LOADLIBES) | 210 $(Q)$(CONFIG_SHELL) $(check-lxdialog) -check $(HOSTCC) $(HOST_EXTRACFLAGS) $(HOSTLOADLIBES_mconf) |
209 210always := dochecklxdialog 211 212# Add environment specific flags 213HOST_EXTRACFLAGS += $(shell $(CONFIG_SHELL) $(srctree)/$(src)/check.sh $(HOSTCC) $(HOSTCFLAGS)) 214 215# generated files seem to need this to find local include files 216HOSTCFLAGS_lex.zconf.o := -I$(src) 217HOSTCFLAGS_zconf.tab.o := -I$(src) 218 219HOSTLOADLIBES_qconf = $(KC_QT_LIBS) -ldl 220HOSTCXXFLAGS_qconf.o = $(KC_QT_CFLAGS) -D LKC_DIRECT_LINK 221 222HOSTLOADLIBES_gconf = `pkg-config --libs gtk+-2.0 gmodule-2.0 libglade-2.0` -ldl 223HOSTCFLAGS_gconf.o = `pkg-config --cflags gtk+-2.0 gmodule-2.0 libglade-2.0` \ 224 -D LKC_DIRECT_LINK 225 | 211 212always := dochecklxdialog 213 214# Add environment specific flags 215HOST_EXTRACFLAGS += $(shell $(CONFIG_SHELL) $(srctree)/$(src)/check.sh $(HOSTCC) $(HOSTCFLAGS)) 216 217# generated files seem to need this to find local include files 218HOSTCFLAGS_lex.zconf.o := -I$(src) 219HOSTCFLAGS_zconf.tab.o := -I$(src) 220 221HOSTLOADLIBES_qconf = $(KC_QT_LIBS) -ldl 222HOSTCXXFLAGS_qconf.o = $(KC_QT_CFLAGS) -D LKC_DIRECT_LINK 223 224HOSTLOADLIBES_gconf = `pkg-config --libs gtk+-2.0 gmodule-2.0 libglade-2.0` -ldl 225HOSTCFLAGS_gconf.o = `pkg-config --cflags gtk+-2.0 gmodule-2.0 libglade-2.0` \ 226 -D LKC_DIRECT_LINK 227 |
228HOSTLOADLIBES_mconf = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ldflags $(HOSTCC)) 229 |
|
226HOSTLOADLIBES_nconf = -lmenu -lpanel -lncurses 227$(obj)/qconf.o: $(obj)/.tmp_qtcheck 228 229ifeq ($(qconf-target),1) 230$(obj)/.tmp_qtcheck: $(src)/Makefile 231-include $(obj)/.tmp_qtcheck 232 233# QT needs some extra effort... --- 111 unchanged lines hidden --- | 230HOSTLOADLIBES_nconf = -lmenu -lpanel -lncurses 231$(obj)/qconf.o: $(obj)/.tmp_qtcheck 232 233ifeq ($(qconf-target),1) 234$(obj)/.tmp_qtcheck: $(src)/Makefile 235-include $(obj)/.tmp_qtcheck 236 237# QT needs some extra effort... --- 111 unchanged lines hidden --- |