Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/distrib/sets Add print_mkvars make target for debug.



details:   https://anonhg.NetBSD.org/src/rev/b371b94cf6cb
branches:  trunk
changeset: 749819:b371b94cf6cb
user:      uebayasi <uebayasi%NetBSD.org@localhost>
date:      Thu Dec 10 05:15:28 2009 +0000

description:
Add print_mkvars make target for debug.

diffstat:

 distrib/sets/Makefile  |   5 ++++-
 distrib/sets/sets.subr |  14 +++++++++++---
 2 files changed, 15 insertions(+), 4 deletions(-)

diffs (61 lines):

diff -r cd2bd09a75db -r b371b94cf6cb distrib/sets/Makefile
--- a/distrib/sets/Makefile     Thu Dec 10 05:10:00 2009 +0000
+++ b/distrib/sets/Makefile     Thu Dec 10 05:15:28 2009 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.73 2009/12/04 12:43:56 apb Exp $
+#      $NetBSD: Makefile,v 1.74 2009/12/10 05:15:28 uebayasi Exp $
 
 # The `all' target must appear before bsd.own.mk is pulled in.
 all:
@@ -67,6 +67,9 @@
 print_toolchain_missing: .PHONY
        @echo "${TOOLCHAIN_MISSING}"
 
+print_mkvars: .PHONY
+       @env SETS_SUBR_DEBUG=dumpmkvars sh sets.subr
+
 #
 # METALOG MANIPULATION TARGETS
 #
diff -r cd2bd09a75db -r b371b94cf6cb distrib/sets/sets.subr
--- a/distrib/sets/sets.subr    Thu Dec 10 05:10:00 2009 +0000
+++ b/distrib/sets/sets.subr    Thu Dec 10 05:15:28 2009 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: sets.subr,v 1.104 2009/12/10 05:02:48 uebayasi Exp $
+#      $NetBSD: sets.subr,v 1.105 2009/12/10 05:15:28 uebayasi Exp $
 #
 
 #
@@ -168,7 +168,6 @@
 
 EOMAKE
 ); do
-#      echo 1>&2 "DEBUG: read $x"
        eval $x
 done
 
@@ -176,6 +175,15 @@
 
 MKVARS="$MKEXTRAVARS $_MKVARS_yes $_MKVARS_no"
 
+if [ "$SETS_SUBR_DEBUG" = "dumpmkvars" ]; then
+       for v in $MKVARS; do
+               eval echo $v=\$$v
+       done
+       exit 0
+fi
+
+#####
+
 setsdir=${0%/*}
 obsolete=0
 module=yes
@@ -219,7 +227,7 @@
 # In each file, a record consists of a path and a System Package name,
 # separated by whitespace. E.g.,
 #
-#      # $NetBSD: sets.subr,v 1.104 2009/12/10 05:02:48 uebayasi Exp $
+#      # $NetBSD: sets.subr,v 1.105 2009/12/10 05:15:28 uebayasi Exp $
 #      .                       base-sys-root   [keyword[,...]]
 #      ./altroot               base-sys-root
 #      ./bin                   base-sys-root



Home | Main Index | Thread Index | Old Index