status-mobile/nix/desktop/macos/default.nix

32 lines
735 B
Nix
Raw Normal View History

{ stdenv, callPackage, pkgs,
darwin, qt5, status-go, baseImageFactory }:
with darwin.apple_sdk.frameworks;
assert stdenv.isDarwin;
let
2019-07-19 18:40:03 +00:00
inherit (stdenv.lib) concatStrings catAttrs;
baseImage = baseImageFactory "macos";
2019-07-19 18:40:03 +00:00
in {
buildInputs = [
pkgs.gnupg22
baseImage
qt5.full
AppKit
Cocoa
darwin.cf-private
Foundation
OpenGL
] ++ status-go.buildInputs;
shellHook =
2019-07-19 18:40:03 +00:00
concatStrings (catAttrs "shellHook" [ baseImage status-go ] ) + ''
export NIX_TARGET_LDFLAGS="-F${CoreFoundation}/Library/Frameworks -framework CoreFoundation $NIX_TARGET_LDFLAGS"
export QT_PATH="${qt5.full}"
export QT_BASEBIN_PATH="${qt5.qtbase.bin}"
export PATH="${qt5.full}/bin:$PATH"
'';
}