summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2006-04-14 17:15:03 +0000
committerjlam <jlam@pkgsrc.org>2006-04-14 17:15:03 +0000
commit1e2d98e634b7cd204c0a9023d2807eb8cb78274e (patch)
tree89f7458491ed083406b721335c171541ab3c8804 /mk
parent28856457ab377654ae379a66de27d333c3b4e942 (diff)
downloadpkgsrc-1e2d98e634b7cd204c0a9023d2807eb8cb78274e.tar.gz
Make the display of show-options more readable when there are lots of
options, e.g. x11/xorg-server, by wordwrapping the output.
Diffstat (limited to 'mk')
-rw-r--r--mk/bsd.options.mk12
1 files changed, 8 insertions, 4 deletions
diff --git a/mk/bsd.options.mk b/mk/bsd.options.mk
index d7404d32ec4..e6e8d5ce768 100644
--- a/mk/bsd.options.mk
+++ b/mk/bsd.options.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.options.mk,v 1.51 2006/04/13 21:45:14 wiz Exp $
+# $NetBSD: bsd.options.mk,v 1.52 2006/04/14 17:15:03 jlam Exp $
#
# This Makefile fragment provides boilerplate code for standard naming
# conventions for handling per-package build options.
@@ -326,6 +326,7 @@ PKG_FAIL_REASON:= "The following selected options are not supported: "${_OPTIONS
PKG_OPTIONS:= ${PKG_OPTIONS:O:u}
_PKG_OPTIONS_WORDWRAP_FILTER= \
+ ${XARGS} -n 1 | \
${AWK} ' \
BEGIN { printwidth = 40; line = "" } \
{ \
@@ -368,8 +369,11 @@ show-options:
. endfor
.endfor
@${ECHO}
- @${ECHO} "These options are enabled by default: "${PKG_SUGGESTED_OPTIONS:O:Q}
- @${ECHO} "These options are currently enabled: "${PKG_OPTIONS:O:Q}
+ @${ECHO} "These options are enabled by default:"
+ @${ECHO} ${PKG_SUGGESTED_OPTIONS:O:Q} | ${_PKG_OPTIONS_WORDWRAP_FILTER}
+ @${ECHO} ""
+ @${ECHO} "These options are currently enabled:"
+ @${ECHO} ${PKG_OPTIONS:O:Q} | ${_PKG_OPTIONS_WORDWRAP_FILTER}
. if defined(PKG_OPTIONS_DEPRECATED_WARNINGS)
@${ECHO}
@for l in ${PKG_OPTIONS_DEPRECATED_WARNINGS}; \
@@ -386,7 +390,7 @@ supported-options-message:
@${ECHO} "=========================================================================="
@${ECHO} "The supported build options for this package are:"
@${ECHO} ""
- @${ECHO} ${PKG_SUPPORTED_OPTIONS:O:Q} | ${XARGS} -n 1 | ${_PKG_OPTIONS_WORDWRAP_FILTER}
+ @${ECHO} ${PKG_SUPPORTED_OPTIONS:O:Q} | ${_PKG_OPTIONS_WORDWRAP_FILTER}
. if !empty(PKG_OPTIONS)
@${ECHO} ""
@${ECHO} "The currently selected options are:"