configure: fix building with -NTP -CMDMON +SCFILTER

Don't enable privileged operations using the nameserv code unless
NTP is enabled.
This commit is contained in:
Miroslav Lichvar
2020-09-08 09:45:13 +02:00
parent 0fcdf4389b
commit ff466439fc
3 changed files with 10 additions and 5 deletions

10
configure vendored
View File

@@ -804,10 +804,12 @@ if [ $feat_scfilter = "1" ] && [ $try_seccomp = "1" ] && \
'seccomp_init(SCMP_ACT_KILL);'
then
add_def FEAT_SCFILTER
# NAME2IPADDRESS shouldn't be enabled with other operations as the helper
# process works on one request at the time and the async resolver could
# block the main thread
priv_ops="NAME2IPADDRESS RELOADDNS"
if [ $feat_ntp = "1" ]; then
# NAME2IPADDRESS shouldn't be enabled together with a privops operation
# used by the main thread as the helper process works on one request at
# a time and the async resolver would block the main thread
priv_ops="NAME2IPADDRESS RELOADDNS"
fi
EXTRA_LIBS="$EXTRA_LIBS -lseccomp"
fi