Skip to content

Commit

Permalink
knot-dns: yet another attempt to fix build on Darwin
Browse files Browse the repository at this point in the history
  • Loading branch information
vcunat committed Jan 31, 2017
1 parent 3ccc139 commit dacbca2
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions pkgs/servers/dns/knot-dns/default.nix
@@ -1,5 +1,5 @@
{ stdenv, fetchurl, pkgconfig, gnutls, jansson, liburcu, lmdb, libcap_ng, libidn
, systemd, nettle, libedit, zlib, libiconv
, systemd, nettle, libedit, zlib, libiconv, fetchpatch
}:

# Note: ATM only the libraries have been tested in nixpkgs.
Expand All @@ -12,6 +12,13 @@ stdenv.mkDerivation rec {
sha256 = "0y9nhp9lfmxv4iy1xg7l4lfxv4168qhag26wwg0dbi0zjpkd790b";
};

patches = stdenv.lib.optional stdenv.isDarwin
(fetchpatch {
name = "before-sierra.diff";
url = "https://gitlab.labs.nic.cz/labs/knot/merge_requests/664.diff";
sha256 = "0g4gm2m3pi0lfpkp53xayf6jq6yn3ifidh40maiy1a46dfadvw6w";
});

outputs = [ "bin" "out" "dev" ];

nativeBuildInputs = [ pkgconfig ];
Expand All @@ -27,7 +34,7 @@ stdenv.mkDerivation rec {

enableParallelBuilding = true;

CFLAGS = [ "-DNDEBUG" ];
CFLAGS = [ "-O2" "-DNDEBUG" ];

#doCheck = true; problems in combination with dynamic linking

Expand Down

0 comments on commit dacbca2

Please sign in to comment.