From 4c56eb81e9522c74b85f2aadf14f619288191dad Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Tue, 18 Sep 2018 20:13:46 -0500 Subject: [PATCH] noti: fix darwin build --- pkgs/tools/misc/noti/default.nix | 6 +++++- pkgs/top-level/all-packages.nix | 4 +++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/misc/noti/default.nix b/pkgs/tools/misc/noti/default.nix index ac5b4199c216..23646abe7875 100644 --- a/pkgs/tools/misc/noti/default.nix +++ b/pkgs/tools/misc/noti/default.nix @@ -1,4 +1,4 @@ -{ stdenv, buildGoPackage, fetchFromGitHub }: +{ stdenv, buildGoPackage, fetchFromGitHub, Cocoa }: buildGoPackage rec { name = "noti-${version}"; @@ -11,6 +11,10 @@ buildGoPackage rec { sha256 = "1chsqfqk0pnhx5k2nr4c16cpb8m6zv69l1jvv4v4903zgfzcm823"; }; + buildInputs = stdenv.lib.optionals stdenv.isDarwin [ Cocoa ]; + # TODO: Remove this when we update apple_sdk + NIX_CFLAGS_COMPILE = stdenv.lib.optionals stdenv.isDarwin [ "-fno-objc-arc" ]; + goPackagePath = "github.com/variadico/noti"; preBuild = '' diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 07133473b808..f0ba3a1552e3 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1467,7 +1467,9 @@ with pkgs; noteshrink = callPackage ../tools/misc/noteshrink { }; - noti = callPackage ../tools/misc/noti { }; + noti = callPackage ../tools/misc/noti { + inherit (darwin.apple_sdk.frameworks) Cocoa; + }; nrsc5 = callPackage ../applications/misc/nrsc5 { };