2008-12-16 18:12:34 +00:00
|
|
|
# Makefile for the scripts/ sub-directory
|
2007-07-01 19:04:20 +00:00
|
|
|
|
|
|
|
# Here, we can update the config.* scripts.
|
|
|
|
# If we're in CT_LIB_DIR, then CT_LIB_DIR == CT_TOP_DIR, and we can update those
|
|
|
|
# scripts for later inclusion mainline. If CT_LIB_DIR != CT_TOP_DIR, then those
|
|
|
|
# scripts are downloaded only for use in CT_TOP_DIR.
|
|
|
|
|
2008-10-27 18:42:26 +00:00
|
|
|
# ----------------------------------------------------------
|
|
|
|
# The tools help entry
|
|
|
|
|
|
|
|
help-distrib::
|
|
|
|
@echo ' updatetools - Update the config tools'
|
|
|
|
|
|
|
|
# ----------------------------------------------------------
|
|
|
|
# Where to get tools from, and where to store them into
|
|
|
|
# The tools are: config.guess and config.sub
|
|
|
|
|
2008-05-08 15:36:51 +00:00
|
|
|
CONFIG_SUB_SRC="http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD"
|
2008-12-16 18:12:34 +00:00
|
|
|
CONFIG_SUB_DEST=scripts/config.sub
|
2008-05-08 15:36:51 +00:00
|
|
|
CONFIG_GUESS_SRC="http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD"
|
2008-12-16 18:12:34 +00:00
|
|
|
CONFIG_GUESS_DEST=scripts/config.guess
|
2007-07-01 19:04:20 +00:00
|
|
|
|
|
|
|
PHONY += updatetools
|
2008-11-13 17:34:44 +00:00
|
|
|
updatetools: $(CONFIG_SUB_DEST) $(CONFIG_GUESS_DEST)
|
2007-07-01 19:04:20 +00:00
|
|
|
|
2008-10-27 18:42:26 +00:00
|
|
|
# ----------------------------------------------------------
|
|
|
|
# How to retrieve the tools
|
|
|
|
|
2017-02-12 21:51:42 +00:00
|
|
|
ifneq ($(strip $(V)),2)
|
|
|
|
wget_silent_opt = -o /dev/null
|
|
|
|
curl_silent_opt = --silent
|
|
|
|
endif
|
|
|
|
|
2018-11-12 09:15:58 +00:00
|
|
|
ifneq ($(CT_WGET),)
|
|
|
|
download_cmd = $(CT_WGET) --passive-ftp $(wget_silent_opt) -O $@
|
2017-02-12 21:51:42 +00:00
|
|
|
else
|
2018-11-12 09:15:58 +00:00
|
|
|
ifneq ($(CT_CURL),)
|
|
|
|
download_cmd = $(CT_CURL) --ftp-pasv $(curl_silent_opt) -o $@
|
2017-02-12 21:51:42 +00:00
|
|
|
else
|
|
|
|
download_cmd = $(error wget or curl needed for downloads)
|
|
|
|
endif
|
2008-11-13 17:34:44 +00:00
|
|
|
endif
|
|
|
|
|
2008-12-16 18:12:34 +00:00
|
|
|
PHONY += scripts
|
|
|
|
scripts:
|
2015-10-30 02:34:24 +00:00
|
|
|
@$(CT_ECHO) ' MKDIR $@'
|
2009-10-30 19:08:44 +00:00
|
|
|
$(SILENT)mkdir -p $@
|
2008-12-16 18:12:34 +00:00
|
|
|
|
2009-10-30 18:49:51 +00:00
|
|
|
$(CONFIG_SUB_DEST): scripts FORCE
|
2017-02-12 21:51:42 +00:00
|
|
|
@$(CT_ECHO) ' DOWNLOAD $@'
|
|
|
|
$(SILENT)$(download_cmd) $(CONFIG_SUB_SRC)
|
Cheesy kconfig stuff:
- silent/quiet/verbose build:
- ct-ng by default only prints quit messages, such as "CC xxx",
- if using V=0, nothing is printed,
- if using V=1, the full command lines are printed,
- other values are indeterminate,
- should help in debugging the kconfig stuff;
- complete kconfig/{,m}conf generation:
- fully dynamic dependencies on source files,
- compilation of .c into .o, then linking (instead of direct linking),
- VPATH usage when not --local;
Typo + a coment moved.
/trunk/kconfig/kconfig.mk | 140 87 53 0 +++++++++++++++++++++++++++++++++--------------------
/trunk/tools/tools.mk | 12 6 6 0 ++--
/trunk/steps.mk | 6 3 3 0 +-
/trunk/samples/samples.mk | 30 15 15 0 +++++-----
/trunk/ct-ng.in | 40 28 12 0 +++++++++++----
5 files changed, 139 insertions(+), 89 deletions(-)
2008-10-15 21:29:56 +00:00
|
|
|
$(SILENT)chmod u+rwx,go+rx-w $@
|
2007-07-01 19:04:20 +00:00
|
|
|
|
2009-10-30 18:49:51 +00:00
|
|
|
$(CONFIG_GUESS_DEST): scripts FORCE
|
2017-02-12 21:51:42 +00:00
|
|
|
@$(CT_ECHO) ' DOWNLOAD $@'
|
|
|
|
$(SILENT)$(download_cmd) $(CONFIG_GUESS_SRC)
|
Cheesy kconfig stuff:
- silent/quiet/verbose build:
- ct-ng by default only prints quit messages, such as "CC xxx",
- if using V=0, nothing is printed,
- if using V=1, the full command lines are printed,
- other values are indeterminate,
- should help in debugging the kconfig stuff;
- complete kconfig/{,m}conf generation:
- fully dynamic dependencies on source files,
- compilation of .c into .o, then linking (instead of direct linking),
- VPATH usage when not --local;
Typo + a coment moved.
/trunk/kconfig/kconfig.mk | 140 87 53 0 +++++++++++++++++++++++++++++++++--------------------
/trunk/tools/tools.mk | 12 6 6 0 ++--
/trunk/steps.mk | 6 3 3 0 +-
/trunk/samples/samples.mk | 30 15 15 0 +++++-----
/trunk/ct-ng.in | 40 28 12 0 +++++++++++----
5 files changed, 139 insertions(+), 89 deletions(-)
2008-10-15 21:29:56 +00:00
|
|
|
$(SILENT)chmod u+rwx,go+rx-w $@
|
2007-02-24 11:00:05 +00:00
|
|
|
|
2008-10-27 18:42:26 +00:00
|
|
|
# ----------------------------------------------------------
|
|
|
|
# Clean up the mess
|
2007-07-01 19:04:20 +00:00
|
|
|
|
|
|
|
distclean::
|
2015-10-30 02:34:24 +00:00
|
|
|
@$(CT_ECHO) " CLEAN scripts"
|
2008-12-16 18:12:34 +00:00
|
|
|
$(SILENT)[ $(CT_TOP_DIR) = $(CT_LIB_DIR) ] || rm -rf $(CT_TOP_DIR)/scripts
|