diff options
author | jlam <jlam@pkgsrc.org> | 2006-07-08 23:10:35 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2006-07-08 23:10:35 +0000 |
commit | c16221a4db5db247e9ecea04d817821955982042 (patch) | |
tree | 04459b5ed42b41d60b93766832b84b0beb86ba13 /mk/buildlink3 | |
parent | c25fbde9c94a010e0b2c953766743f818b86c9ea (diff) | |
download | pkgsrc-c16221a4db5db247e9ecea04d817821955982042.tar.gz |
Change the format of BUILDLINK_ORDER to contain depth information as well,
and add a new helper target and script, "show-buildlink3", that outputs
a listing of the buildlink3.mk files included as well as the depth at
which they are included.
For example, "make show-buildlink3" in fonts/Xft2 displays:
zlib
fontconfig
iconv
zlib
freetype2
expat
freetype2
Xrender
renderproto
Diffstat (limited to 'mk/buildlink3')
-rw-r--r-- | mk/buildlink3/bsd.buildlink3.mk | 6 | ||||
-rw-r--r-- | mk/buildlink3/show-buildlink3.sh | 23 |
2 files changed, 28 insertions, 1 deletions
diff --git a/mk/buildlink3/bsd.buildlink3.mk b/mk/buildlink3/bsd.buildlink3.mk index 7c33469362c..8e5417d1651 100644 --- a/mk/buildlink3/bsd.buildlink3.mk +++ b/mk/buildlink3/bsd.buildlink3.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.buildlink3.mk,v 1.181 2006/07/07 21:24:28 jlam Exp $ +# $NetBSD: bsd.buildlink3.mk,v 1.182 2006/07/08 23:11:17 jlam Exp $ # # Copyright (c) 2004 The NetBSD Foundation, Inc. # All rights reserved. @@ -1072,3 +1072,7 @@ do-buildlink: ### ### END: after the barrier ### + +.PHONY: show-buildlink3 +show-buildlink3: + @${SH} ${PKGSRCDIR}/mk/buildlink3/show-buildlink3.sh ${BUILDLINK_ORDER} diff --git a/mk/buildlink3/show-buildlink3.sh b/mk/buildlink3/show-buildlink3.sh new file mode 100644 index 00000000000..1d2255158d2 --- /dev/null +++ b/mk/buildlink3/show-buildlink3.sh @@ -0,0 +1,23 @@ +#!/bin/sh +# +# $NetBSD: show-buildlink3.sh,v 1.1 2006/07/08 23:11:17 jlam Exp $ +# +# This script is a helper for the show-buildlink3 target and outputs +# the arguments, each on a new line with any leading "+" signs replaced +# with four spaces. +# + +while test $# -gt 0; do + pkg="$1" + pkg="${pkg#+}" + prefix= + stripped=no + while test $stripped = no; do + case $pkg in + +*) prefix=" $prefix"; pkg="${pkg#+}"; stripped=no ;; + *) stripped=yes ;; + esac + done + echo "$prefix$pkg" + shift +done |