From 21d3bf00333f27c04acd41117956ccd3ecf839b7 Mon Sep 17 00:00:00 2001 From: JailBird Date: Wed, 20 Jan 2021 22:06:36 -0600 Subject: [PATCH 1/3] New package: tinycdb-0.78 --- common/shlibs | 1 + srcpkgs/libtinycdb | 1 + srcpkgs/tinycdb-devel | 1 + srcpkgs/tinycdb/template | 47 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 50 insertions(+) create mode 100644 srcpkgs/libtinycdb create mode 100644 srcpkgs/tinycdb-devel create mode 100644 srcpkgs/tinycdb/template diff --git a/common/shlibs b/common/shlibs index e030495fd63..befbc2ebe97 100644 --- a/common/shlibs +++ b/common/shlibs @@ -4045,3 +4045,4 @@ libutil-cmdline-samba4.so samba-libs-4.13.2_1 libwinbind-client-samba4.so samba-libs-4.13.2_1 libsixel.so.1 libsixel-1.8.6_1 libpamtest.so.0 pam_wrapper-1.1.3_1 +libcdb.so.1 libtinycdb-0.78_1 diff --git a/srcpkgs/libtinycdb b/srcpkgs/libtinycdb new file mode 100644 index 00000000000..e81cc9c1516 --- /dev/null +++ b/srcpkgs/libtinycdb @@ -0,0 +1 @@ +tinycdb \ No newline at end of file diff --git a/srcpkgs/tinycdb-devel b/srcpkgs/tinycdb-devel new file mode 100644 index 00000000000..e81cc9c1516 --- /dev/null +++ b/srcpkgs/tinycdb-devel @@ -0,0 +1 @@ +tinycdb \ No newline at end of file diff --git a/srcpkgs/tinycdb/template b/srcpkgs/tinycdb/template new file mode 100644 index 00000000000..fa09a9c1db0 --- /dev/null +++ b/srcpkgs/tinycdb/template @@ -0,0 +1,47 @@ +# Template file for 'tinycdb' +pkgname=tinycdb +version=0.78 +revision=1 +build_style=gnu-makefile +make_build_target=shared +make_build_args="LD=\$(CC)" +short_desc="Alternative constant database library" +maintainer="JailBird " +license="Public Domain" +homepage="http://www.corpit.ru/mjt/tinycdb.html" +distfiles="http://www.corpit.ru/mjt/${pkgname}/${pkgname}-${version}.tar.gz" +checksum=50678f432d8ada8d69f728ec11c3140e151813a7847cf30a62d86f3a720ed63c + +do_install() { + vbin cdb-shared cdb + + vinstall libcdb.so.1 755 usr/lib + vinstall cdb.h 644 usr/include + + for f in 1 3 5; do + vman cdb.${f} + done + + vmkdir $DESTDIR/usr/lib + ln -s libcdb.so.1 $DESTDIR/usr/lib/libcdb.so + + vdoc ChangeLog + vdoc NEWS +} + +libtinycdb_package() { + short_desc+=" - shared library" + pkg_install() { + vmove "usr/lib/libcdb.so.*" + } +} + +tinycdb-devel_package() { + depends="libtinycdb>=${version}_${revision}" + short_desc+=" - development files" + pkg_install() { + vmove usr/include + vmove "usr/lib/*.so" + vmove usr/share/man/man3 + } +} From 66934e5865e9f550ee4989ced3315f9a2e6faec1 Mon Sep 17 00:00:00 2001 From: JailBird Date: Wed, 20 Jan 2021 22:14:22 -0600 Subject: [PATCH 2/3] Fix tab/space mix --- srcpkgs/tinycdb/template | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/srcpkgs/tinycdb/template b/srcpkgs/tinycdb/template index fa09a9c1db0..9995add84f4 100644 --- a/srcpkgs/tinycdb/template +++ b/srcpkgs/tinycdb/template @@ -22,8 +22,8 @@ do_install() { vman cdb.${f} done - vmkdir $DESTDIR/usr/lib - ln -s libcdb.so.1 $DESTDIR/usr/lib/libcdb.so + vmkdir $DESTDIR/usr/lib + ln -s libcdb.so.1 $DESTDIR/usr/lib/libcdb.so vdoc ChangeLog vdoc NEWS From 4111f479813bc799b369b16e93bbac8c99814e0b Mon Sep 17 00:00:00 2001 From: JailBird Date: Fri, 22 Jan 2021 19:52:13 -0600 Subject: [PATCH 3/3] New package: dnsdist-1.5.1 --- srcpkgs/dnsdist/files/dnsdist.conf | 27 +++++++++++++++++++++ srcpkgs/dnsdist/files/dnsdist/run | 2 ++ srcpkgs/dnsdist/template | 39 ++++++++++++++++++++++++++++++ srcpkgs/dnsdist/update | 1 + 4 files changed, 69 insertions(+) create mode 100644 srcpkgs/dnsdist/files/dnsdist.conf create mode 100644 srcpkgs/dnsdist/files/dnsdist/run create mode 100644 srcpkgs/dnsdist/template create mode 100644 srcpkgs/dnsdist/update diff --git a/srcpkgs/dnsdist/files/dnsdist.conf b/srcpkgs/dnsdist/files/dnsdist.conf new file mode 100644 index 00000000000..d9c2dd7804a --- /dev/null +++ b/srcpkgs/dnsdist/files/dnsdist.conf @@ -0,0 +1,27 @@ +-- Example (simple) configuration + +--[[ By default, dnsdist binds to 127.0.0.1:53 and uses exactly one thread + To use more threads, we need to explicitly set the first thread listener + with setLocal() reusePort=true and then add one addLocal() for each + additional thread. Eg, for a 4-thread setup: --]] +-- setLocal("127.0.0.1:53", {reusePort=true, tcpFastOpenQueueSize=2048}) +-- addLocal("127.0.0.1:53", {reusePort=true, tcpFastOpenQueueSize=2048}) +-- addLocal("127.0.0.1:53", {reusePort=true, tcpFastOpenQueueSize=2048}) +-- addLocal("127.0.0.1:53", {reusePort=true, tcpFastOpenQueueSize=2048}) + +-- Throw requests to Cloudflare and Google and take the fastest answer + +-- newServer("2606:4700:4700::1111") -- Cloudflare, primary IPv6 +newServer("1.1.1.1") -- Cloudflare, primary IPv4 +-- newServer("2001:4860:4860::8888") -- Google, primary IPv6 +newServer("8.8.8.8") -- Google, primary IPv4 +-- newServer("2606:4700:4700::1001") -- Cloudflare, secondary IPv6 +newServer("1.0.0.1") -- Cloudflare, secondary IPv4 +-- newServer("2001:4860:4860::8844") -- Google, secondary IPv6 +newServer("8.8.4.4") -- Google, secondary IPv4 + +setServerPolicy(roundrobin) + +-- Basic caching of results, comment out to use less memory +pc = newPacketCache(10000, {maxTTL=86400, minTTL=0, temporaryFailureTTL=60, staleTTL=60, dontAge=false}) +getPool(""):setCache(pc) diff --git a/srcpkgs/dnsdist/files/dnsdist/run b/srcpkgs/dnsdist/files/dnsdist/run new file mode 100644 index 00000000000..8af24c5a744 --- /dev/null +++ b/srcpkgs/dnsdist/files/dnsdist/run @@ -0,0 +1,2 @@ +#!/bin/sh +exec chpst -o 2048 dnsdist --uid _dnsdist --gid _dnsdist --supervised --disable-syslog diff --git a/srcpkgs/dnsdist/template b/srcpkgs/dnsdist/template new file mode 100644 index 00000000000..422dd74cded --- /dev/null +++ b/srcpkgs/dnsdist/template @@ -0,0 +1,39 @@ +# Template file for 'dnsdist' +pkgname=dnsdist +version=1.5.1 +revision=1 +build_style=gnu-configure +configure_args="--with-pic --with-gnu-ld --with-libsodium --with-protobuf + --with-re2 --with-net-snmp --with-libcap --with-libssl --enable-dnscrypt + --with-libcrypto=${XBPS_CROSS_BASE}/usr --with-service-user=_dnsdist + --with-service-group=_dnsdist --sbindir=/usr/bin --with-gnutls --with-lmdb + --enable-dns-over-tls --enable-dns-over-https --sysconfdir=/etc/dnsdist" +conf_files="/etc/dnsdist/dnsdist.conf" +makedepends="libsodium-devel protobuf25 protobuf25-devel boost-devel re2-devel + net-snmp-devel libcap-devel LuaJIT-devel libressl-devel lmdb-devel fstrm-devel + libedit-devel gnutls-devel tinycdb-devel h2o-devel" +depends="libsodium libprotobuf25-lite re2 libnet-snmp libcap LuaJIT libressl lmdb + fstrm libedit gnutls tinycdb" +hostmakedepends="autoconf automake pkgconf" +short_desc="Dynamic DNS loadbalancer" +maintainer="JailBird " +license="GPL-2.0-only" +homepage="https://dnsdist.org/" +distfiles="https://downloads.powerdns.com/releases/${pkgname}-${version}.tar.bz2" +checksum=cae759729a87703f4d09b0ed4227cb224aaaa252fa92f2432fd7116f560afbf1 + +system_accounts="_dnsdist" + +pre_configure() { + export CPPFLAGS="-I${XBPS_CROSS_BASE}/usr/include" + export LDFLAGS="-L${XBPS_CROSS_BASE}/usr/lib" + export PKG_CONFIG_PATH=${XBPS_CROSS_BASE}/usr/lib/pkgconfig + export LMDB_LIBS="-llmdb" +} + +post_install() { + vsconf dnsdistconf.lua dnsdist.conf + vinstall ${FILESDIR}/dnsdist.conf 644 etc/dnsdist + vsv dnsdist + vlicense COPYING +} diff --git a/srcpkgs/dnsdist/update b/srcpkgs/dnsdist/update new file mode 100644 index 00000000000..da8e072d218 --- /dev/null +++ b/srcpkgs/dnsdist/update @@ -0,0 +1 @@ +ignore="*alpha[0-9]* *rc[0-9]* *beta[0-9]*"