2016-09-17 23:30:27 +02:00
|
|
|
{ stdenv, fetchurl, pkgconfig,
|
|
|
|
boost, libyamlcpp, libsodium, sqlite, protobuf,
|
2017-12-27 17:00:39 +01:00
|
|
|
mysql57, postgresql, lua, openldap, geoip, curl
|
2016-09-17 23:30:27 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "powerdns-${version}";
|
2017-11-27 18:33:18 +01:00
|
|
|
version = "4.0.5";
|
2016-09-17 23:30:27 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://downloads.powerdns.com/releases/pdns-${version}.tar.bz2";
|
2017-11-27 18:33:18 +01:00
|
|
|
sha256 = "097ci4s2c63gl0bil8yh87dsy0sk3fds4w8cpyjh5kns6zazmj2v";
|
2016-09-17 23:30:27 +02:00
|
|
|
};
|
|
|
|
|
2017-09-05 23:26:13 +02:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
2017-12-27 17:00:39 +01:00
|
|
|
buildInputs = [ boost mysql57.connector-c postgresql lua openldap sqlite protobuf geoip libyamlcpp libsodium curl ];
|
2016-09-17 23:30:27 +02:00
|
|
|
|
|
|
|
# nix destroy with-modules arguments, when using configureFlags
|
|
|
|
preConfigure = ''
|
|
|
|
configureFlagsArray=(
|
|
|
|
"--with-modules=bind gmysql geoip gpgsql gsqlite3 ldap lua pipe random remote"
|
|
|
|
--with-sqlite3
|
|
|
|
--with-socketdir=/var/lib/powerdns
|
|
|
|
--enable-libsodium
|
|
|
|
--enable-tools
|
|
|
|
--disable-dependency-tracking
|
|
|
|
--disable-silent-rules
|
|
|
|
--enable-reproducible
|
|
|
|
--enable-unit-tests
|
|
|
|
)
|
|
|
|
'';
|
|
|
|
checkPhase = "make check";
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Authoritative DNS server";
|
2017-08-22 20:50:04 +02:00
|
|
|
homepage = https://www.powerdns.com;
|
2016-09-17 23:30:27 +02:00
|
|
|
platforms = platforms.linux;
|
|
|
|
# cannot find postgresql libs on macos x
|
|
|
|
license = licenses.gpl2;
|
2017-10-18 20:49:23 +02:00
|
|
|
maintainers = [ maintainers.mic92 ];
|
2016-09-17 23:30:27 +02:00
|
|
|
};
|
|
|
|
}
|