aboutsummaryrefslogtreecommitdiffstats
path: root/rules.mk
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2010-10-10 22:40:44 +0000
committerJo-Philipp Wich <jow@openwrt.org>2010-10-10 22:40:44 +0000
commit720cb42823968bbf40b52976de6c4a577ef77ac3 (patch)
tree5f557a8a16a270472ede56d8e15b62db8db30e8f /rules.mk
parent496a4e657d4b0c470c9e55781a12c0de9c2eb675 (diff)
downloadupstream-720cb42823968bbf40b52976de6c4a577ef77ac3.tar.gz
upstream-720cb42823968bbf40b52976de6c4a577ef77ac3.tar.bz2
upstream-720cb42823968bbf40b52976de6c4a577ef77ac3.zip
[buildroot] Add two debug rules the examine the values of runtime make variables.
Based on patch by Philip Prindeville <philipp@redfish-solutions.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@23389 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'rules.mk')
-rw-r--r--rules.mk12
1 files changed, 12 insertions, 0 deletions
diff --git a/rules.mk b/rules.mk
index 49044c8cfb..7d3516bc42 100644
--- a/rules.mk
+++ b/rules.mk
@@ -254,4 +254,16 @@ all:
FORCE: ;
.PHONY: FORCE
+val.%:
+ @$(if $(filter undefined,$(origin $*)),\
+ echo "$* undefined" >&2, \
+ echo '$(subst ','"'"',$($*))' \
+ )
+
+var.%:
+ @$(if $(filter undefined,$(origin $*)),\
+ echo "$* undefined" >&2, \
+ echo "$*='"'$(subst ','"'\"'\"'"',$($*))'"'" \
+ )
+
endif #__rules_inc