2007-02-24 11:00:05 +00:00
|
|
|
# ===========================================================================
|
2007-07-02 19:40:54 +00:00
|
|
|
# crosstool-NG configuration targets
|
2007-02-24 11:00:05 +00:00
|
|
|
# These targets are used from top-level makefile
|
|
|
|
|
2008-10-14 16:50:33 +00:00
|
|
|
#-----------------------------------------------------------
|
|
|
|
# The configurators rules
|
2007-07-01 19:04:20 +00:00
|
|
|
|
2017-04-23 06:33:36 +00:00
|
|
|
# Top file of crosstool-NG configuration
|
|
|
|
export KCONFIG_TOP = $(CT_LIB_DIR)/config/config.in
|
2008-10-19 09:34:32 +00:00
|
|
|
|
2012-05-06 22:27:05 +00:00
|
|
|
# We need CONF for savedefconfig in scripts/saveSample.sh
|
|
|
|
export CONF := $(CT_LIB_DIR)/kconfig/conf
|
2012-01-14 17:22:06 +00:00
|
|
|
MCONF := $(CT_LIB_DIR)/kconfig/mconf
|
|
|
|
NCONF := $(CT_LIB_DIR)/kconfig/nconf
|
|
|
|
|
2017-04-23 06:33:36 +00:00
|
|
|
# Used by conf/mconf/nconf to find the .in files
|
|
|
|
export srctree=$(CT_LIB_DIR)
|
|
|
|
|
2012-01-14 17:22:06 +00:00
|
|
|
menuconfig:
|
2017-04-23 06:33:36 +00:00
|
|
|
@$(CT_ECHO) " CONF $@"
|
2012-01-14 17:22:06 +00:00
|
|
|
$(SILENT)$(MCONF) $(KCONFIG_TOP)
|
2007-02-24 11:00:05 +00:00
|
|
|
|
2012-01-14 17:22:06 +00:00
|
|
|
nconfig:
|
2017-04-23 06:33:36 +00:00
|
|
|
@$(CT_ECHO) " CONF $@"
|
2012-01-14 17:22:06 +00:00
|
|
|
$(SILENT)$(NCONF) $(KCONFIG_TOP)
|
2011-05-12 17:45:30 +00:00
|
|
|
|
2012-01-14 17:22:06 +00:00
|
|
|
oldconfig: .config
|
2017-04-23 06:33:36 +00:00
|
|
|
@$(CT_ECHO) " CONF $@"
|
2017-07-06 07:13:03 +00:00
|
|
|
$(SILENT)$(sed) -i -r -f $(CT_LIB_DIR)/scripts/upgrade.sed $<
|
2012-01-14 17:22:06 +00:00
|
|
|
$(SILENT)$(CONF) --silent$@ $(KCONFIG_TOP)
|
2007-02-24 11:00:05 +00:00
|
|
|
|
2013-01-21 23:34:15 +00:00
|
|
|
savedefconfig: .config
|
2015-10-30 02:34:24 +00:00
|
|
|
@$(CT_ECHO) ' GEN $@'
|
2013-07-17 06:25:43 +00:00
|
|
|
$(SILENT)$(CONF) --savedefconfig=$${DEFCONFIG-defconfig} $(KCONFIG_TOP)
|
2012-08-15 20:06:22 +00:00
|
|
|
|
2013-01-21 23:34:15 +00:00
|
|
|
defconfig:
|
2015-10-30 02:34:24 +00:00
|
|
|
@$(CT_ECHO) ' CONF $@'
|
2013-07-17 06:25:43 +00:00
|
|
|
$(SILENT)$(CONF) --defconfig=$${DEFCONFIG-defconfig} $(KCONFIG_TOP)
|
2012-08-15 20:06:22 +00:00
|
|
|
|
2010-02-11 20:28:10 +00:00
|
|
|
# Always be silent, the stdout an be >.config
|
|
|
|
extractconfig:
|
2012-07-14 16:25:47 +00:00
|
|
|
@$(awk) 'BEGIN { dump=0; } \
|
2014-10-21 17:20:22 +00:00
|
|
|
dump==1 && $$0~/^\[.....\][[:space:]]+(# )?CT_/ { \
|
2012-07-14 16:25:47 +00:00
|
|
|
$$1=""; \
|
|
|
|
gsub("^[[:space:]]",""); \
|
|
|
|
print; \
|
|
|
|
} \
|
|
|
|
$$0~/Dumping user-supplied crosstool-NG configuration: done in/ { \
|
|
|
|
dump=0; \
|
|
|
|
} \
|
|
|
|
$$0~/Dumping user-supplied crosstool-NG configuration$$/ { \
|
|
|
|
dump=1; \
|
|
|
|
}'
|
2010-02-11 20:28:10 +00:00
|
|
|
|
2008-10-14 16:50:33 +00:00
|
|
|
#-----------------------------------------------------------
|
2007-02-24 11:00:05 +00:00
|
|
|
# Help text used by make help
|
2008-10-14 16:50:33 +00:00
|
|
|
|
2007-06-17 16:24:23 +00:00
|
|
|
help-config::
|
2007-08-15 14:59:37 +00:00
|
|
|
@echo ' menuconfig - Update current config using a menu based program'
|
2015-09-01 23:11:30 +00:00
|
|
|
@echo ' nconfig - Update current config using a menu based program'
|
2007-08-15 14:59:37 +00:00
|
|
|
@echo ' oldconfig - Update current config using a provided .config as base'
|
2010-02-11 20:28:10 +00:00
|
|
|
@echo ' extractconfig - Extract to stdout the configuration items from a'
|
|
|
|
@echo ' build.log file piped to stdin'
|
2013-07-17 06:25:43 +00:00
|
|
|
@echo ' savedefconfig - Save current config as a mini-defconfig to $${DEFCONFIG}'
|
|
|
|
@echo ' defconfig - Update config from a mini-defconfig $${DEFCONFIG}'
|
|
|
|
@echo ' (default: $${DEFCONFIG}=./defconfig)'
|