2018-02-17 11:47:20 +00:00
|
|
|
{ stdenv, fetchurl, pkgconfig
|
2019-01-12 12:17:12 +00:00
|
|
|
, boost, libyamlcpp, libsodium, sqlite, protobuf, botan2, libressl
|
2018-02-17 11:47:20 +00:00
|
|
|
, mysql57, postgresql, lua, openldap, geoip, curl, opendbx, unixODBC
|
2016-09-17 22:30:27 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "powerdns-${version}";
|
2019-02-11 21:45:31 +00:00
|
|
|
version = "4.1.6";
|
2016-09-17 22:30:27 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2018-06-28 19:43:35 +01:00
|
|
|
url = "https://downloads.powerdns.com/releases/pdns-${version}.tar.bz2";
|
2019-02-11 21:45:31 +00:00
|
|
|
sha256 = "0ggpcvzj90a31qf71m8788ql0hbxnkb9y6c3wgqr9l0qwv8dsgpm";
|
2016-09-17 22:30:27 +01:00
|
|
|
};
|
|
|
|
|
2017-09-05 22:26:13 +01:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
2018-02-17 11:47:20 +00:00
|
|
|
buildInputs = [
|
|
|
|
boost mysql57.connector-c postgresql lua openldap sqlite protobuf geoip
|
2019-01-12 12:17:12 +00:00
|
|
|
libyamlcpp libsodium curl opendbx unixODBC botan2 libressl
|
2018-02-17 11:47:20 +00:00
|
|
|
];
|
2016-09-17 22:30:27 +01:00
|
|
|
|
|
|
|
# nix destroy with-modules arguments, when using configureFlags
|
|
|
|
preConfigure = ''
|
|
|
|
configureFlagsArray=(
|
2018-02-17 11:47:20 +00:00
|
|
|
"--with-modules=bind gmysql geoip godbc gpgsql gsqlite3 ldap lua mydns opendbx pipe random remote"
|
2016-09-17 22:30:27 +01:00
|
|
|
--with-sqlite3
|
|
|
|
--with-socketdir=/var/lib/powerdns
|
2019-01-12 12:17:12 +00:00
|
|
|
--with-libcrypto=${libressl.dev}
|
2016-09-17 22:30:27 +01:00
|
|
|
--enable-libsodium
|
2018-02-17 11:47:20 +00:00
|
|
|
--enable-botan
|
2016-09-17 22:30:27 +01:00
|
|
|
--enable-tools
|
|
|
|
--disable-dependency-tracking
|
|
|
|
--disable-silent-rules
|
|
|
|
--enable-reproducible
|
|
|
|
--enable-unit-tests
|
|
|
|
)
|
|
|
|
'';
|
2018-02-17 11:47:20 +00:00
|
|
|
|
|
|
|
doCheck = true;
|
2016-09-17 22:30:27 +01:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Authoritative DNS server";
|
2017-08-22 19:50:04 +01:00
|
|
|
homepage = https://www.powerdns.com;
|
2016-09-17 22:30:27 +01:00
|
|
|
platforms = platforms.linux;
|
|
|
|
# cannot find postgresql libs on macos x
|
|
|
|
license = licenses.gpl2;
|
2018-03-18 00:30:44 +00:00
|
|
|
maintainers = with maintainers; [ mic92 disassembler ];
|
2016-09-17 22:30:27 +01:00
|
|
|
};
|
|
|
|
}
|