dnsdist: make re2 support optional

Signed-off-by: Peter van Dijk <peter.van.dijk@powerdns.com>
This commit is contained in:
Peter van Dijk 2021-04-22 23:45:02 +02:00
parent e8c8c5cce0
commit 6d8fb2091c

View file

@ -68,6 +68,12 @@ menu "Configuration"
help help
"Enable Net-SNMP support for dnsdist" "Enable Net-SNMP support for dnsdist"
default y default y
config DNSDIST_RE2
bool "RE2 support"
help
"Enable RE2 support for dnsdist"
default y
endmenu endmenu
endef endef
@ -81,13 +87,14 @@ define Package/dnsdist
+DNSDIST_GNUTLS:libgnutls \ +DNSDIST_GNUTLS:libgnutls \
+DNSDIST_OPENSSL:libopenssl \ +DNSDIST_OPENSSL:libopenssl \
+DNSDIST_NET_SNMP:libnetsnmp \ +DNSDIST_NET_SNMP:libnetsnmp \
+DNSDIST_RE2:re2 \
+libatomic \ +libatomic \
+libcap \ +libcap \
+libedit \ +libedit \
+libfstrm \ +libfstrm \
+libsodium \ +libsodium \
+libstdcpp \
+lmdb \ +lmdb \
+re2 \
+liblua \ +liblua \
+tinycdb +tinycdb
URL:=https://dnsdist.org/ URL:=https://dnsdist.org/
@ -108,14 +115,21 @@ endef
# not everything groks --disable-nls # not everything groks --disable-nls
DISABLE_NLS:= DISABLE_NLS:=
# OpenWRT's setting of CXX destroys dnsdist's -std=c++17
# --with-re2 compensates for that because it compensates for a bug in re2.pc that also destroys it
# so this addition is for the --without-re2 case
#
# none of this is pretty
TARGET_CXX+=-std=c++17
CONFIGURE_ARGS+= \ CONFIGURE_ARGS+= \
--enable-option-checking=fatal \ --enable-option-checking=fatal \
--enable-dnscrypt \ --enable-dnscrypt \
--enable-dnstap \ --enable-dnstap \
--with-libsodium \ --with-libsodium \
--with-pic \ --with-pic \
--with-re2 \
--with-lua=lua \ --with-lua=lua \
$(if $(CONFIG_DNSDIST_RE2),--with,--without)-re2 \
$(if $(CONFIG_DNSDIST_NET_SNMP),--with,--without)-net-snmp \ $(if $(CONFIG_DNSDIST_NET_SNMP),--with,--without)-net-snmp \
$(if $(CONFIG_DNSDIST_GNUTLS),--with,--without)-gnutls \ $(if $(CONFIG_DNSDIST_GNUTLS),--with,--without)-gnutls \
$(if $(CONFIG_DNSDIST_OPENSSL),--with,--without)-libssl \ $(if $(CONFIG_DNSDIST_OPENSSL),--with,--without)-libssl \