mirror of
https://github.com/crosstool-ng/crosstool-ng.git
synced 2025-01-30 08:03:59 +00:00
Get rid of the tols/ directory:
- move config.guess and config.sub from tools/ into scripts/ - update the scripts and makefile fragments accordingly /trunk/Makefile.in | 10 5 5 0 +++++----- /trunk/scripts/functions | 16 8 8 0 ++++++++-------- /trunk/scripts/scripts.mk | 28 13 15 0 +++++++++++++--------------- /trunk/ct-ng.in | 4 2 2 0 ++-- 4 files changed, 28 insertions(+), 30 deletions(-)
This commit is contained in:
parent
7915426092
commit
65bb3ac67c
10
Makefile.in
10
Makefile.in
@ -39,7 +39,7 @@ TARGETS := bin lib doc man
|
||||
|
||||
build: $(patsubst %,build-%,$(TARGETS))
|
||||
|
||||
install: real-install
|
||||
install: build real-install
|
||||
|
||||
clean: $(patsubst %,clean-%,$(TARGETS))
|
||||
|
||||
@ -100,7 +100,7 @@ clean-man:
|
||||
|
||||
ifeq ($(strip $(LOCAL)),1)
|
||||
|
||||
real-install: build
|
||||
real-install:
|
||||
@echo " CHMOD 'ct-ng'"
|
||||
@chmod a+x ct-ng
|
||||
|
||||
@ -112,7 +112,7 @@ else
|
||||
#--------------------------------------
|
||||
# Install rules
|
||||
|
||||
real-install: build $(patsubst %,install-%,$(TARGETS))
|
||||
real-install: $(patsubst %,install-%,$(TARGETS))
|
||||
|
||||
install-bin: $(DESTDIR)$(BINDIR)
|
||||
@echo " INST 'ct-ng'"
|
||||
@ -125,11 +125,11 @@ install-bin: $(DESTDIR)$(BINDIR)
|
||||
install-lib: uninstall-lib $(DESTDIR)$(LIBDIR) install-lib-main install-lib-samples
|
||||
|
||||
install-lib-main: $(DESTDIR)$(LIBDIR)
|
||||
@for src_dir in config kconfig patches scripts tools; do \
|
||||
@for src_dir in config kconfig patches scripts; do \
|
||||
echo " INST '$${src_dir}/'"; \
|
||||
tar cf - --exclude=.svn $${src_dir} |(cd "$(DESTDIR)$(LIBDIR)"; tar xf -); \
|
||||
done
|
||||
@rm -f "$(DESTDIR)$(LIBDIR)/tools/addToolVersion.sh"
|
||||
@rm -f "$(DESTDIR)$(LIBDIR)/scripts/addToolVersion.sh"
|
||||
@echo " INST 'steps.mk'"
|
||||
@install -m 644 steps.mk "$(DESTDIR)$(LIBDIR)/steps.mk"
|
||||
|
||||
|
4
ct-ng.in
4
ct-ng.in
@ -50,7 +50,7 @@ ifeq ($(strip $(origin V)),command line)
|
||||
endif # origin V
|
||||
export V SILENT ECHO
|
||||
|
||||
.FORCE:
|
||||
.FORCE: $(FORCE)
|
||||
.PHONY: $(PHONY)
|
||||
PHONY += all
|
||||
all: help
|
||||
@ -103,7 +103,7 @@ include $(CT_LIB_DIR)/config/config.mk
|
||||
include $(CT_LIB_DIR)/kconfig/kconfig.mk
|
||||
include $(CT_LIB_DIR)/steps.mk
|
||||
include $(CT_LIB_DIR)/samples/samples.mk
|
||||
include $(CT_LIB_DIR)/tools/tools.mk
|
||||
include $(CT_LIB_DIR)/scripts/scripts.mk
|
||||
|
||||
help-distrib::
|
||||
@echo ' tarball - Build a tarball of the configured toolchain'
|
||||
|
0
tools/config.sub → scripts/config.sub
vendored
0
tools/config.sub → scripts/config.sub
vendored
@ -617,8 +617,8 @@ CT_ExtractAndPatch() {
|
||||
if [ "${CT_OVERIDE_CONFIG_GUESS_SUB}" = "y" ]; then
|
||||
CT_DoLog ALL "Overiding config.guess and config.sub"
|
||||
for cfg in config_guess config_sub; do
|
||||
eval ${cfg}="${CT_LIB_DIR}/tools/${cfg/_/.}"
|
||||
[ -e "${CT_TOP_DIR}/tools/${cfg/_/.}" ] && eval ${cfg}="${CT_TOP_DIR}/tools/${cfg/_/.}"
|
||||
eval ${cfg}="${CT_LIB_DIR}/scripts/${cfg/_/.}"
|
||||
[ -e "${CT_TOP_DIR}/scripts/${cfg/_/.}" ] && eval ${cfg}="${CT_TOP_DIR}/scripts/${cfg/_/.}"
|
||||
# Can't use CT_DoExecLog because of the '{} \;' to be passed un-mangled to find
|
||||
find . -type f -name "${cfg/_/.}" -exec cp -v "${!cfg}" {} \; |CT_DoLog ALL
|
||||
done
|
||||
@ -630,18 +630,18 @@ CT_ExtractAndPatch() {
|
||||
# Two wrappers to call config.(guess|sub) either from CT_TOP_DIR or CT_LIB_DIR.
|
||||
# Those from CT_TOP_DIR, if they exist, will be be more recent than those from CT_LIB_DIR.
|
||||
CT_DoConfigGuess() {
|
||||
if [ -x "${CT_TOP_DIR}/tools/config.guess" ]; then
|
||||
"${CT_TOP_DIR}/tools/config.guess"
|
||||
if [ -x "${CT_TOP_DIR}/scripts/config.guess" ]; then
|
||||
"${CT_TOP_DIR}/scripts/config.guess"
|
||||
else
|
||||
"${CT_LIB_DIR}/tools/config.guess"
|
||||
"${CT_LIB_DIR}/scripts/config.guess"
|
||||
fi
|
||||
}
|
||||
|
||||
CT_DoConfigSub() {
|
||||
if [ -x "${CT_TOP_DIR}/tools/config.sub" ]; then
|
||||
"${CT_TOP_DIR}/tools/config.sub" "$@"
|
||||
if [ -x "${CT_TOP_DIR}/scripts/config.sub" ]; then
|
||||
"${CT_TOP_DIR}/scripts/config.sub" "$@"
|
||||
else
|
||||
"${CT_LIB_DIR}/tools/config.sub" "$@"
|
||||
"${CT_LIB_DIR}/scripts/config.sub" "$@"
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Makefile for the tools/ sub-directory
|
||||
# Makefile for the scripts/ sub-directory
|
||||
|
||||
# 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
|
||||
@ -16,17 +16,9 @@ help-distrib::
|
||||
# The tools are: config.guess and config.sub
|
||||
|
||||
CONFIG_SUB_SRC="http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD"
|
||||
CONFIG_SUB_DEST=tools/config.sub
|
||||
CONFIG_SUB_DEST=scripts/config.sub
|
||||
CONFIG_GUESS_SRC="http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD"
|
||||
CONFIG_GUESS_DEST=tools/config.guess
|
||||
|
||||
# Kludge: we have a step that is called 'tools', and thus we can not define a
|
||||
# rule here that is named 'tools'. Naming it 'tools/' does not help either.
|
||||
# Thus, prepend the top directory to have a single rule description. This is
|
||||
# not as bad as it seems, because it is only refered to by teo rules in this
|
||||
# file, but still it is a kludge...
|
||||
$(CT_TOP_DIR)/tools:
|
||||
$(SILENT)mkdir -p tools
|
||||
CONFIG_GUESS_DEST=scripts/config.guess
|
||||
|
||||
PHONY += updatetools
|
||||
updatetools: $(CONFIG_SUB_DEST) $(CONFIG_GUESS_DEST)
|
||||
@ -39,12 +31,18 @@ ifeq ($(strip $(V)),2)
|
||||
wget_opt=
|
||||
endif
|
||||
|
||||
$(CONFIG_SUB_DEST): .FORCE $(CT_TOP_DIR)/tools
|
||||
PHONY += scripts
|
||||
scripts:
|
||||
$(SILENT)mkdir -p scripts
|
||||
|
||||
FROCE += $(CONFIG_SUB_DEST)
|
||||
$(CONFIG_SUB_DEST): scripts
|
||||
@$(ECHO) ' WGET $@'
|
||||
$(SILENT)wget $(wget_opt) -O $@ $(CONFIG_SUB_SRC)
|
||||
$(SILENT)chmod u+rwx,go+rx-w $@
|
||||
|
||||
$(CONFIG_GUESS_DEST): .FORCE $(CT_TOP_DIR)/tools
|
||||
FORCE += $(CONFIG_GUESS_DEST)
|
||||
$(CONFIG_GUESS_DEST): scripts
|
||||
@$(ECHO) ' WGET $@'
|
||||
$(SILENT)wget $(wget_opt) -O $@ $(CONFIG_GUESS_SRC)
|
||||
$(SILENT)chmod u+rwx,go+rx-w $@
|
||||
@ -53,5 +51,5 @@ $(CONFIG_GUESS_DEST): .FORCE $(CT_TOP_DIR)/tools
|
||||
# Clean up the mess
|
||||
|
||||
distclean::
|
||||
@$(ECHO) " CLEAN tools"
|
||||
$(SILENT)[ $(CT_TOP_DIR) = $(CT_LIB_DIR) ] || rm -rf $(CT_TOP_DIR)/tools
|
||||
@$(ECHO) " CLEAN scripts"
|
||||
$(SILENT)[ $(CT_TOP_DIR) = $(CT_LIB_DIR) ] || rm -rf $(CT_TOP_DIR)/scripts
|
Loading…
x
Reference in New Issue
Block a user