summaryrefslogtreecommitdiff
path: root/tools/Makefile
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2015-02-05 16:57:35 +0000
committerJo-Philipp Wich <jow@openwrt.org>2015-02-05 16:57:35 +0000
commita546f511f2fb2150c7bbf912cbae55c0ebe710a4 (patch)
treebd3b11ee5a3b0432d65e2bfb57db013476651c94 /tools/Makefile
parent16e1d82460ce939daeceac857c2de207e34468c7 (diff)
downloadmtk-20170518-a546f511f2fb2150c7bbf912cbae55c0ebe710a4.zip
mtk-20170518-a546f511f2fb2150c7bbf912cbae55c0ebe710a4.tar.gz
mtk-20170518-a546f511f2fb2150c7bbf912cbae55c0ebe710a4.tar.bz2
tools: remove PrepareCommand macros
They're part of prereq-build.mk now. Signed-off-by: Jo-Philipp Wich <jow@openwrt.org> SVN-Revision: 44274
Diffstat (limited to 'tools/Makefile')
-rw-r--r--tools/Makefile41
1 files changed, 2 insertions, 39 deletions
diff --git a/tools/Makefile b/tools/Makefile
index c508819..b4938d3 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -111,47 +111,10 @@ $(STAGING_DIR_HOST)/.prepared: $(TMP_DIR)/.build
ln -sf lib $(STAGING_DIR_HOST)/lib64
touch $@
-
-define PrepareCommand
-$(STAGING_DIR_HOST)/bin/$(1): $(STAGING_DIR)/.prepared
- @mkdir -p "$$(dir $$@)"; rm -f "$$@"
- @export FILE="$$$$(which $(2) 2>/dev/null | grep -v 'not found' | head -n1)"; [ -n "$$$$FILE" ] || { \
- echo "Command $(1) not found."; false; \
- }; ln -s "$$$$FILE" "$$@"
-
-endef
endif
-$(STAGING_DIR_HOST)/bin/stat: $(STAGING_DIR)/.prepared
- @rm -f $@
- @if stat --version > /dev/null 2>&1; then \
- ln -s `which stat` $@; \
- elif gstat --version > /dev/null 2>&1; then \
- ln -s `which gstat` $@; \
- elif gnustat --version > /dev/null 2>&1; then \
- ln -s `which gnustat` $@; \
- else \
- echo "GNU stat not found"; \
- false; \
- fi
-
-$(STAGING_DIR_HOST)/bin/ldconfig: $(STAGING_DIR)/.prepared
- touch $@
- chmod +x $@
-
-$(eval $(call PrepareCommand,md5sum,gmd5sum md5sum $(SCRIPT_DIR)/md5sum))
-$(eval $(call PrepareCommand,cp,gcp cp))
-$(eval $(call PrepareCommand,seq,gseq seq))
-$(eval $(call PrepareCommand,python,python2 python2.7 python))
-$(eval $(call PrepareCommand,awk,gawk awk))
-$(eval $(call PrepareCommand,getopt,gnugetopt /usr/local/bin/getopt getopt))
-$(eval $(call PrepareCommand,grep,ggrep grep))
-$(eval $(call PrepareCommand,tar,gtar tar))
-$(eval $(call PrepareCommand,diff,gdiff diff))
-
-$(curdir)/cmddeps = $(patsubst %,$(STAGING_DIR_HOST)/bin/%,md5sum cp stat seq python awk getopt grep tar diff ldconfig)
-$(curdir)//prepare = $(STAGING_DIR)/.prepared $(STAGING_DIR_HOST)/.prepared $($(curdir)/cmddeps)
-$(curdir)//compile = $(STAGING_DIR)/.prepared $(STAGING_DIR_HOST)/.prepared $($(curdir)/cmddeps)
+$(curdir)//prepare = $(STAGING_DIR)/.prepared $(STAGING_DIR_HOST)/.prepared
+$(curdir)//compile = $(STAGING_DIR)/.prepared $(STAGING_DIR_HOST)/.prepared
# prerequisites for the individual targets
$(curdir)/ := .config prereq