aboutsummaryrefslogtreecommitdiff
path: root/Mk/bsd.port.mk
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2013-06-14 06:56:16 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2013-06-14 06:56:16 +0000
commit632f0ed926512bfd3636c1b844e5679260d65a86 (patch)
treee6fd1e6ddbe79be0135ac2279ccf5e38a45350fc /Mk/bsd.port.mk
parent11bc9c3ef455d08f9f580c0dadc440b4fa62adf2 (diff)
downloadports-632f0ed926512bfd3636c1b844e5679260d65a86.tar.gz
ports-632f0ed926512bfd3636c1b844e5679260d65a86.zip
Notes
Diffstat (limited to 'Mk/bsd.port.mk')
-rw-r--r--Mk/bsd.port.mk26
1 files changed, 5 insertions, 21 deletions
diff --git a/Mk/bsd.port.mk b/Mk/bsd.port.mk
index 14344c8a0914..934d8c6440eb 100644
--- a/Mk/bsd.port.mk
+++ b/Mk/bsd.port.mk
@@ -6185,11 +6185,7 @@ showconfig:
.if !empty(COMPLETE_OPTIONS_LIST)
@${ECHO_MSG} "===> The following configuration options are available for ${PKGNAME}":
.for opt in ${ALL_OPTIONS}
-. if empty(PORT_OPTIONS:M${opt})
- @${ECHO_MSG} -n " ${opt}=off"
-. else
- @${ECHO_MSG} -n " ${opt}=on"
-. endif
+ @[ -z "${PORT_OPTIONS:M${opt}}" ] || match="on" ; ${ECHO_MSG} -n " ${opt}=$${match:-off}"
. if !empty(${opt}_DESC)
@${ECHO_MSG} -n ": "${${opt}_DESC:Q}
. endif
@@ -6205,11 +6201,7 @@ showconfig:
@${ECHO_MSG} "====> ${${m}_DESC}${${otype}_EOL}"
. endif
. for opt in ${OPTIONS_${otype}_${m}}
-. if ${PORT_OPTIONS:M${opt}}
- @${ECHO_MSG} -n " ${opt}=on"
-. else
- @${ECHO_MSG} -n " ${opt}=off"
-. endif
+ @[ -z "${PORT_OPTIONS:M${opt}}" ] || match="on" ; ${ECHO_MSG} -n " ${opt}=$${match:-off}"
. if !empty(${opt}_DESC)
@${ECHO_MSG} -n ": "${${opt}_DESC:Q}
. endif
@@ -6271,22 +6263,14 @@ RADIO_START= (
RADIO_END= )
pretty-print-config:
.for opt in ${ALL_OPTIONS}
-. if empty(PORT_OPTIONS:M${opt})
- @${ECHO_MSG} -n "-${opt} "
-. else
- @${ECHO_MSG} -n "+${opt} "
-. endif
+ @[ -z "${PORT_OPTIONS:M${opt}}" ] || match="+" ; ${ECHO_MSG} -n "$${match:--}${opt} "
.endfor
.for otype in MULTI GROUP SINGLE RADIO
. for m in ${OPTIONS_${otype}}
@${ECHO_MSG} -n "${m}${${otype}_START} "
. for opt in ${OPTIONS_${otype}_${m}}
-. if ${PORT_OPTIONS:M${opt}}
- @${ECHO_MSG} -n "+${opt} "
-. else
- @${ECHO_MSG} -n "-${opt} "
-. endif
-. endfor
+ @[ -z "${PORT_OPTIONS:M${opt}}" ] || match="+" ; ${ECHO_MSG} -n "$${match:--}${opt} "
+. endfor
@${ECHO_MSG} -n "${${otype}_END} "
. endfor
.endfor