Index: branches/2018Q2/dns/dnsdist/Makefile =================================================================== --- branches/2018Q2/dns/dnsdist/Makefile (revision 466190) +++ branches/2018Q2/dns/dnsdist/Makefile (revision 466191) @@ -1,52 +1,77 @@ # Created by: Carlos J Puga Medina # $FreeBSD$ PORTNAME= dnsdist DISTVERSION= 1.3.0 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= dns net MASTER_SITES= https://downloads.powerdns.com/releases/ \ LOCAL/cpm MAINTAINER= cpm@FreeBSD.org COMMENT= Highly DNS-, DoS- and abuse-aware loadbalancer LICENSE= GPLv2 UNLICENSE LICENSE_COMB= multi LICENSE_FILE_UNLICENSE= ${WRKSRC}/ext/incbin/UNLICENSE BUILD_DEPENDS= ${LOCALBASE}/lib/libatomic_ops.a:devel/libatomic_ops LIB_DEPENDS= libboost_serialization.so:devel/boost-libs \ libprotobuf.so:devel/protobuf \ libre2.so:devel/re2 \ libsodium.so:security/libsodium GNU_CONFIGURE= yes -USES= bison compiler cpe gmake libedit libtool localbase lua:52 \ +USES= bison compiler cpe gmake libedit libtool localbase \ pkgconfig tar:bz2 CONFIGURE_ARGS= --bindir=${PREFIX}/sbin \ + --enable-dns-over-tls \ --enable-dnscrypt \ --enable-libsodium \ --enable-re2 INSTALL_TARGET= install-strip USERS= _dnsdist GROUPS= _dnsdist USE_RC_SUBR= dnsdist + +OPTIONS_DEFINE= FSTRM LUAJIT SNMP +OPTIONS_DEFAULT= GNUTLS OPENSSL +OPTIONS_MULTI= TLS +OPTIONS_MULTI_TLS= GNUTLS OPENSSL + +FSTRM_DESC= dnstap support (see dnstap.info) +LUAJIT_DESC= Use LuaJIT instead of Lua + +FSTRM_LIB_DEPENDS= libfstrm.so:devel/fstrm +FSTRM_CONFIGURE_ENABLE= fstrm + +GNUTLS_LIB_DEPENDS= libgnutls.so:security/gnutls +GNUTLS_CONFIGURE_ENABLE=gnutls + +LUAJIT_LIB_DEPENDS= libluajit-5.1.so.2:lang/luajit +LUAJIT_USES_OFF= lua +LUAJIT_CONFIGURE_WITH= luajit + +OPENSSL_USES= ssl +OPENSSL_CONFIGURE_ENABLE=libssl + +SNMP_LIB_DEPENDS= libnetsnmp.so:net-mgmt/net-snmp +SNMP_CONFIGURE_WITH= net-snmp .include # Fix dnsdist binaries when building on FreeBSD 10.3 .if ${OPSYS} == FreeBSD && ${OSVERSION} < 1100000 BUILD_DEPENDS+= clang50:devel/llvm50 CC= clang50 CXX= clang++50 .endif post-install: ${INSTALL_DATA} ${FILESDIR}/dnsdist.conf.sample \ ${STAGEDIR}${PREFIX}/etc .include Index: branches/2018Q2/dns/dnsdist/files/dnsdist.in =================================================================== --- branches/2018Q2/dns/dnsdist/files/dnsdist.in (revision 466190) +++ branches/2018Q2/dns/dnsdist/files/dnsdist.in (revision 466191) @@ -1,28 +1,31 @@ #!/bin/sh # # $FreeBSD$ # # PROVIDE: dnsdist # REQUIRE: NETWORKING DAEMON # KEYWORD: shutdown # # Add the following line to /etc/rc.conf to enable dnsdist: # # dnsdist_enable="YES" . /etc/rc.subr desc="dnsdist is a powerful, scriptable DNS loadbalancer" name=dnsdist rcvar=dnsdist_enable load_rc_config ${name} : ${dnsdist_priv_user:=_dnsdist} : ${dnsdist_priv_group:=_dnsdist} : ${dnsdist_enable:=NO} -command=/usr/local/sbin/${name} -command_args="-u ${dnsdist_priv_user} -g ${dnsdist_priv_group}" +pidfile=/var/run/${name}.pid + +command=/usr/sbin/daemon +actual_command=/usr/local/sbin/${name} +command_args="-c -f -r -P ${pidfile} ${actual_command} -u ${dnsdist_priv_user} -g ${dnsdist_priv_group} --supervised" run_rc_command "$1" Index: branches/2018Q2/dns/dnsdist/files/patch-ext_luawrapper_include_LuaContext.hpp =================================================================== --- branches/2018Q2/dns/dnsdist/files/patch-ext_luawrapper_include_LuaContext.hpp (nonexistent) +++ branches/2018Q2/dns/dnsdist/files/patch-ext_luawrapper_include_LuaContext.hpp (revision 466191) @@ -0,0 +1,28 @@ +--- ext/luawrapper/include/LuaContext.hpp.orig 2018-03-29 15:25:58 UTC ++++ ext/luawrapper/include/LuaContext.hpp +@@ -2635,11 +2635,21 @@ struct LuaContext::Reader + static auto read(lua_State* state, int index) + -> boost::optional + { ++ std::string result; ++ ++ // lua_tolstring might convert the variable that would confuse lua_next, so we ++ // make a copy of the variable. ++ lua_pushvalue(state, index); ++ + size_t len; +- const auto val = lua_tolstring(state, index, &len); +- if (val == 0) +- return boost::none; +- return std::string(val, len); ++ const auto val = lua_tolstring(state, -1, &len); ++ ++ if (val != 0) ++ result.assign(val, len); ++ ++ lua_pop(state, 1); ++ ++ return val != 0 ? boost::optional{ std::move(result) } : boost::none; + } + }; + Property changes on: branches/2018Q2/dns/dnsdist/files/patch-ext_luawrapper_include_LuaContext.hpp ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: branches/2018Q2 =================================================================== --- branches/2018Q2 (revision 466190) +++ branches/2018Q2 (revision 466191) Property changes on: branches/2018Q2 ___________________________________________________________________ Modified: svn:mergeinfo ## -0,0 +0,1 ## Merged /head:r466166