summaryrefslogtreecommitdiffstats
path: root/Mk/bsd.options.mk
diff options
context:
space:
mode:
authortijl <tijl@FreeBSD.org>2013-06-10 08:37:14 +0000
committertijl <tijl@FreeBSD.org>2013-06-10 08:37:14 +0000
commite8eb72b0902c4fd17dac9d9abeac4a0119c20e03 (patch)
tree09dd731788498c231aa3533a14b6f2c34370c1a4 /Mk/bsd.options.mk
parent3fbf4dfbcc4aa695db32f47a1380c1bf221a9dc1 (diff)
downloadFreeBSD-ports-e8eb72b0902c4fd17dac9d9abeac4a0119c20e03.zip
FreeBSD-ports-e8eb72b0902c4fd17dac9d9abeac4a0119c20e03.tar.gz
Exclude options directly from OPTIONS_DEFINE and set ALL_OPTIONS
later. This simplifies the NO_OPTIONS_SORT case. Approved by: bapt
Diffstat (limited to 'Mk/bsd.options.mk')
-rw-r--r--Mk/bsd.options.mk27
1 files changed, 6 insertions, 21 deletions
diff --git a/Mk/bsd.options.mk b/Mk/bsd.options.mk
index 9e2faba..3db6831 100644
--- a/Mk/bsd.options.mk
+++ b/Mk/bsd.options.mk
@@ -51,9 +51,6 @@ OPTIONSMKINCLUDED= bsd.options.mk
OPTIONSFILE?= ${PORT_DBDIR}/${UNIQUENAME}/options
-#ALL_OPTIONS= DOCS \
-# NLS
-
GLOBAL_OPTIONS= DOCS NLS EXAMPLES IPV6
# Set the default values for the global options, as defined by portmgr
@@ -85,18 +82,10 @@ OPTIONS_DEFAULT+= ${opt}
.endif
.endfor
-# Append options set by the port Makefile
-.for opt in ${OPTIONS_DEFINE}
-ALL_OPTIONS+= ${opt}
-.endfor
-
-ALL_OPTIONS:= ${ALL_OPTIONS:O:u}
-OPTIONS_DEFAULT:= ${OPTIONS_DEFAULT:O:u}
-
# Remove options the port maintainer doesn't want
.for opt in ${OPTIONS_EXCLUDE_${ARCH}} ${OPTIONS_EXCLUDE} ${OPTIONS_SLAVE}
OPTIONS_DEFAULT:= ${OPTIONS_DEFAULT:N${opt}}
-ALL_OPTIONS:= ${ALL_OPTIONS:N${opt}}
+OPTIONS_DEFINE:= ${OPTIONS_DEFINE:N${opt}}
PORT_OPTIONS:= ${PORT_OPTIONS:N${opt}}
. for single in ${OPTIONS_SINGLE}
OPTIONS_SINGLE_${single}:= ${OPTIONS_SINGLE_${single}:N${opt}}
@@ -135,6 +124,10 @@ OPTIONS_MULTI:= ${OPTIONS_MULTI:N${multi}}
.endif
.endfor
+# Sort options
+ALL_OPTIONS:= ${OPTIONS_DEFINE:O:u}
+OPTIONS_DEFAULT:= ${OPTIONS_DEFAULT:O:u}
+
# complete list
COMPLETE_OPTIONS_LIST= ${ALL_OPTIONS}
.for single in ${OPTIONS_SINGLE}
@@ -282,15 +275,7 @@ WITHOUT_NLS= yes
.endif
.if defined(NO_OPTIONS_SORT)
-_SORTED_OPTIONS:= ${ALL_OPTIONS}
-ALL_OPTIONS:=
-.for opt in ${OPTIONS_DEFINE}
-.if ${_SORTED_OPTIONS:M${opt}}
-ALL_OPTIONS+= ${opt}
-.endif
-.endfor
-.undef opt
-.undef _SORTED_OPTIONS
+ALL_OPTIONS= ${OPTIONS_DEFINE}
.endif
### to be removed once old OPTIONS disappear
OpenPOWER on IntegriCloud