svn commit: r431877 - head/Mk
Mathieu Arnold
mat at FreeBSD.org
Thu Jan 19 14:07:27 UTC 2017
Author: mat
Date: Thu Jan 19 14:07:26 2017
New Revision: 431877
URL: https://svnweb.freebsd.org/changeset/ports/431877
Log:
Improve the error message when conflicting OPTIONS_RADIO or
OPTIONS_SINGLE are defined.
PR: 216150
Submitted by: stb lassitu de
Sponsored by: Absolight
Modified:
head/Mk/bsd.port.mk (contents, props changed)
Modified: head/Mk/bsd.port.mk
==============================================================================
--- head/Mk/bsd.port.mk Thu Jan 19 14:06:37 2017 (r431876)
+++ head/Mk/bsd.port.mk Thu Jan 19 14:07:26 2017 (r431877)
@@ -4616,6 +4616,7 @@ pre-check-config:
. for opt in ${OPTIONS_SINGLE_${single}}
. if empty(ALL_OPTIONS:M${single}) || !empty(PORT_OPTIONS:M${single})
. if !empty(PORT_OPTIONS:M${opt})
+OPTIONS_WRONG_SINGLE_${single}+= ${opt}
. if defined(OPTFOUND)
OPTIONS_WRONG_SINGLE+= ${single}
. else
@@ -4640,6 +4641,7 @@ OPTIONS_WRONG_SINGLE+= ${single}
.for radio in ${OPTIONS_RADIO}
. for opt in ${OPTIONS_RADIO_${radio}}
. if !empty(PORT_OPTIONS:M${opt})
+OPTIONS_WRONG_RADIO_${radio}+= ${opt}
. if defined(OPTFOUND)
OPTIONS_WRONG_RADIO+= ${radio}
. else
@@ -4692,9 +4694,11 @@ _check-config: pre-check-config
.endfor
.for single in ${OPTIONS_WRONG_SINGLE}
@${ECHO_MSG} "====> You must select one and only one option from the ${single} single"
+ @${ECHO_MSG} "=====> Only one of these must be defined: ${OPTIONS_WRONG_SINGLE_${single}}"
.endfor
.for radio in ${OPTIONS_WRONG_RADIO}
@${ECHO_MSG} "====> You cannot select multiple options from the ${radio} radio"
+ @${ECHO_MSG} "=====> Only one of these must be defined: ${OPTIONS_WRONG_RADIO_${radio}}"
.endfor
.if defined(OPTIONS_WRONG_PREVENTS)
@${ECHO_MSG} "====> Two or more enabled options conflict with each other"
More information about the svn-ports-all
mailing list