From 189fbae95b4f328287777e6e752a20f67f6d3eef Mon Sep 17 00:00:00 2001 From: Patrick Mahoney Date: Mon, 10 Dec 2018 16:43:24 -0600 Subject: [PATCH 1/2] ldns: relax platform requirements Seems to have built OK on darwin. I only needed it to build freeswitch though, so not sure how to test functionality. I successfully ran the `drill` command. --- pkgs/development/libraries/ldns/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/ldns/default.nix b/pkgs/development/libraries/ldns/default.nix index c4120e5bb0eb..468ab90edb5b 100644 --- a/pkgs/development/libraries/ldns/default.nix +++ b/pkgs/development/libraries/ldns/default.nix @@ -65,7 +65,7 @@ stdenv.mkDerivation rec { description = "Library with the aim of simplifying DNS programming in C"; license = licenses.bsd3; homepage = http://www.nlnetlabs.nl/projects/ldns/; - platforms = platforms.linux; + platforms = platforms.unix; maintainers = with maintainers; [ jgeerds ]; }; } From 5234948642f5a257a44fe6a5f1f11e3e0e5e71f8 Mon Sep 17 00:00:00 2001 From: Patrick Mahoney Date: Mon, 10 Dec 2018 16:49:26 -0600 Subject: [PATCH 2/2] freeswitch: build on darwin - relax platform requirement - include required apple framework --- pkgs/servers/sip/freeswitch/default.nix | 9 ++++++--- pkgs/top-level/all-packages.nix | 1 + 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/pkgs/servers/sip/freeswitch/default.nix b/pkgs/servers/sip/freeswitch/default.nix index 32acba433b12..ab4147230a92 100644 --- a/pkgs/servers/sip/freeswitch/default.nix +++ b/pkgs/servers/sip/freeswitch/default.nix @@ -1,6 +1,9 @@ { fetchurl, stdenv, ncurses, curl, pkgconfig, gnutls, readline , openssl, perl, sqlite, libjpeg, speex, pcre -, ldns, libedit, yasm, which, lua, libopus, libsndfile }: +, ldns, libedit, yasm, which, lua, libopus, libsndfile + +, SystemConfiguration +}: stdenv.mkDerivation rec { name = "freeswitch-1.6.20"; @@ -20,7 +23,7 @@ stdenv.mkDerivation rec { openssl ncurses curl gnutls readline perl libjpeg sqlite pcre speex ldns libedit yasm which lua libopus libsndfile - ]; + ] ++ stdenv.lib.optionals stdenv.isDarwin [ SystemConfiguration ]; NIX_CFLAGS_COMPILE = "-Wno-error"; @@ -31,6 +34,6 @@ stdenv.mkDerivation rec { homepage = https://freeswitch.org/; license = stdenv.lib.licenses.mpl11; maintainers = with stdenv.lib.maintainers; [ ]; - platforms = with stdenv.lib.platforms; linux; + platforms = with stdenv.lib.platforms; unix; }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index d85a1ddf9a1a..a157a53dc6f3 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -13435,6 +13435,7 @@ in freeswitch = callPackage ../servers/sip/freeswitch { openssl = openssl_1_0_2; + inherit (darwin.apple_sdk.frameworks) SystemConfiguration; }; fusionInventory = callPackage ../servers/monitoring/fusion-inventory { };