summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorAbdoulaye Walsimou Gaye <awg@embtoolkit.org>2012-01-08 11:20:43 +0100
committerAbdoulaye Walsimou Gaye <awg@embtoolkit.org>2012-01-08 11:20:43 +0100
commitabcde7965004490a2f9d275f52e0360f092f1417 (patch)
tree6e6d33ad47b39793b41cc0d54014a7ca20810ce3 /mk
parent4a75974316cf23805324518a45eeec089a85ec88 (diff)
downloadembtoolkit-abcde7965004490a2f9d275f52e0360f092f1417.tar.gz
embtoolkit-abcde7965004490a2f9d275f52e0360f092f1417.tar.bz2
embtoolkit-abcde7965004490a2f9d275f52e0360f092f1417.tar.xz
Toolchain: symlink tools just after toolchain build
Signed-off-by: Abdoulaye Walsimou Gaye <awg@embtoolkit.org>
Diffstat (limited to 'mk')
-rw-r--r--mk/buildsystem.mk3
-rw-r--r--mk/toolchain.mk19
2 files changed, 10 insertions, 12 deletions
diff --git a/mk/buildsystem.mk b/mk/buildsystem.mk
index 002407f..5907814 100644
--- a/mk/buildsystem.mk
+++ b/mk/buildsystem.mk
@@ -86,8 +86,7 @@ startbuild:
echo "# Starting build of selected features.."; \
echo "##############################################################"; \
echo; \
- make buildtoolchain host_packages_build symlink_tools rootfs_build \
- successful_build; \
+ $(MAKE) buildtoolchain host_packages_build rootfs_build successful_build; \
fi
# Successful build of EmbToolkit message
diff --git a/mk/toolchain.mk b/mk/toolchain.mk
index 459c7ea..d45c693 100644
--- a/mk/toolchain.mk
+++ b/mk/toolchain.mk
@@ -1,6 +1,6 @@
################################################################################
# Abdoulaye Walsimou GAYE <awg@embtoolkit.org>
-# Copyright(C) 2009-2011 Abdoulaye Walsimou GAYE.
+# Copyright(C) 2009-2012 Abdoulaye Walsimou GAYE.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -98,17 +98,16 @@ TOOLCHAIN_DEPS += gcc2_install $(TOOLCHAIN_CLIB)_install gcc3_install
include $(EMBTK_ROOT)/mk/$(TOOLCHAIN_CLIB).mk
buildtoolchain: $(TOOLCHAIN_POST_DEPS) $(TOOLCHAIN_DEPS)
+ $(Q)$(__embtk_toolchain_symlinktools)
$(call embtk_pinfo,"$(STRICT_GNU_TARGET) toolchain successfully built!")
-symlink_tools:
- @cd $(TOOLS)/bin/; export TOOLS_LIST="`ls $(STRICT_GNU_TARGET)-*`"; \
- for i in $$TOOLS_LIST;do \
- TOOLS_NAME=$$TOOLS_NAME" ""`echo $$i | sed 's/$(STRICT_GNU_TARGET)-*//'`" ; \
- done; \
- export TOOLS_NAME; \
- for i in $$TOOLS_NAME;do \
- ln -sf $(STRICT_GNU_TARGET)-$$i $(GNU_TARGET)-$$i; \
- done
+__embtk_toolchain_symlinktools = $(shell \
+ cd $(TOOLS)/bin; \
+ tools=$$(ls $(STRICT_GNU_TARGET)-*); \
+ toolsnames=$$(echo $$tools | sed 's/$(STRICT_GNU_TARGET)-*//g'); \
+ for tool in $$toolsnames; do \
+ ln -sf $(STRICT_GNU_TARGET)-$$tool $(GNU_TARGET)-$$tool; \
+ done)
# Download target for offline build
packages_fetch:: $(patsubst %_install,download_%,$(TOOLCHAINBUILD))