From 6d64024734d661acd71d2eeb6eb86823b7689998 Mon Sep 17 00:00:00 2001 From: Cole Mickens Date: Wed, 22 Aug 2018 13:57:22 -0700 Subject: [PATCH] keybase: 2.1.0 -> 2.5.0 (#44698) --- pkgs/tools/security/keybase/default.nix | 9 ++++++--- pkgs/top-level/all-packages.nix | 9 ++++++++- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/pkgs/tools/security/keybase/default.nix b/pkgs/tools/security/keybase/default.nix index 1bccd4c9f957..beea202a9562 100644 --- a/pkgs/tools/security/keybase/default.nix +++ b/pkgs/tools/security/keybase/default.nix @@ -1,8 +1,10 @@ -{ stdenv, buildGoPackage, fetchFromGitHub }: +{ stdenv, lib, buildGoPackage, fetchFromGitHub +, AVFoundation ? null, AudioToolbox ? null, ImageIO ? null, CoreMedia ? null +, Foundation ? null, CoreGraphics ? null, MediaToolbox ? null }: buildGoPackage rec { name = "keybase-${version}"; - version = "2.1.0"; + version = "2.5.0"; goPackagePath = "github.com/keybase/client"; subPackages = [ "go/keybase" ]; @@ -13,9 +15,10 @@ buildGoPackage rec { owner = "keybase"; repo = "client"; rev = "v${version}"; - sha256 = "16izsx5944byc930i6pqsbyrp316yyy8z5xvmzj0g8rgawajdx5h"; + sha256 = "0fa55nizld8q0szhlpsf75ifb53js3crh98xmf8mn4bvms7d0x09"; }; + buildInputs = lib.optionals stdenv.isDarwin [ AVFoundation AudioToolbox ImageIO CoreMedia Foundation CoreGraphics MediaToolbox ]; buildFlags = [ "-tags production" ]; meta = with stdenv.lib; { diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 2e372fe4fdf3..82c68a7bcb31 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3407,7 +3407,14 @@ with pkgs; kexectools = callPackage ../os-specific/linux/kexectools { }; - keybase = callPackage ../tools/security/keybase { }; + keybase = callPackage ../tools/security/keybase { + # Reasoning for the inherited apple_sdk.frameworks: + # 1. specific compiler errors about: AVFoundation, AudioToolbox, MediaToolbox + # 2. the rest are added from here: https://github.com/keybase/client/blob/68bb8c893c5214040d86ea36f2f86fbb7fac8d39/go/chat/attachments/preview_darwin.go#L7 + # #cgo LDFLAGS: -framework AVFoundation -framework CoreFoundation -framework ImageIO -framework CoreMedia -framework Foundation -framework CoreGraphics -lobjc + # with the exception of CoreFoundation, due to the warning in https://github.com/NixOS/nixpkgs/blob/master/pkgs/os-specific/darwin/apple-sdk/frameworks.nix#L25 + inherit (darwin.apple_sdk.frameworks) AVFoundation AudioToolbox ImageIO CoreMedia Foundation CoreGraphics MediaToolbox; + }; kbfs = callPackage ../tools/security/kbfs { };