summaryrefslogtreecommitdiffstats
path: root/tools/build
diff options
context:
space:
mode:
authoremaste <emaste@FreeBSD.org>2013-06-10 13:55:03 +0000
committeremaste <emaste@FreeBSD.org>2013-06-10 13:55:03 +0000
commit793c8410e6ea82ff4971a557cc80e74a31e3b1c5 (patch)
tree136c78cbbde24a186b1a5bbdb4e2beb1611df0af /tools/build
parent015913b3831336ed004e485e122a772a0d8c5a67 (diff)
downloadFreeBSD-src-793c8410e6ea82ff4971a557cc80e74a31e3b1c5.zip
FreeBSD-src-793c8410e6ea82ff4971a557cc80e74a31e3b1c5.tar.gz
Handle options that override other options
This is a workaround for WITH_LDNS_UTILS forcing BIND_UTILS off. It can be reverted when we no longer have these conflicting options, or made more general if we grow more cases like this.
Diffstat (limited to 'tools/build')
-rwxr-xr-xtools/build/options/makeman23
1 files changed, 18 insertions, 5 deletions
diff --git a/tools/build/options/makeman b/tools/build/options/makeman
index 61c0776..f619bc1 100755
--- a/tools/build/options/makeman
+++ b/tools/build/options/makeman
@@ -198,7 +198,12 @@ that can be used for source builds.
.Bl -tag -width indent
EOF
show settings SRCCONF=/dev/null | sort > $t/config_default
- show with SRCCONF=/dev/null | sort > $t/config_WITH_ALL
+ # Work around WITH_LDNS_UTILS forcing BIND_UTILS off by parsing the
+ # actual config that results from enabling every WITH_ option. This
+ # can be reverted if/when we no longer have options that disable
+ # others.
+ show with SRCCONF=/dev/null | sort | sed 's/$/=/' > $t/src.conf
+ show settings SRCCONF=$t/src.conf | sort > $t/config_WITH_ALL
show without SRCCONF=/dev/null | sort > $t/config_WITHOUT_ALL
show_options |
@@ -229,6 +234,18 @@ EOF
exit 1
fi
+ show settings SRCCONF=/dev/null -D${opt} | sort > $t/config_${opt}
+ comm -13 $t/config_default $t/config_${opt} | sed -n "/^${opt}$/!p" |
+ comm -13 $t/deps - > $t/deps2
+
+ # Work around BIND_UTILS=no being the default when every WITH_
+ # option is enabled.
+ if [ "$(cat $t/deps2)" == WITHOUT_BIND_UTILS ]; then
+ sort $t/deps $t/deps2 > $t/_deps
+ mv $t/_deps $t/deps
+ :> $t/deps2
+ fi
+
if [ -s $t/deps ] ; then
echo 'When set, it also enforces the following options:'
echo '.Pp'
@@ -240,10 +257,6 @@ EOF
echo '.El'
fi
- show settings SRCCONF=/dev/null -D${opt} | sort > $t/config_${opt}
- comm -13 $t/config_default $t/config_${opt} | sed -n "/^${opt}$/!p" |
- comm -13 $t/deps - > $t/deps2
-
if [ -s $t/deps2 ] ; then
if [ -s $t/deps ] ; then
echo '.Pp'
OpenPOWER on IntegriCloud