From c2013d056ad649145b902ea24203f640c8871a91 Mon Sep 17 00:00:00 2001 From: figsoda Date: Wed, 17 May 2023 13:05:38 -0400 Subject: [PATCH] libmongocrypt: fix build on aarch64-darwin --- .../libraries/libmongocrypt/default.nix | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/libmongocrypt/default.nix b/pkgs/development/libraries/libmongocrypt/default.nix index bfa0a4236b47..d2d22f4cf8c1 100644 --- a/pkgs/development/libraries/libmongocrypt/default.nix +++ b/pkgs/development/libraries/libmongocrypt/default.nix @@ -1,4 +1,14 @@ -{ stdenv, lib, fetchFromGitHub, fetchpatch, cmake, pkg-config, mongoc, openssl }: +{ lib +, stdenv +, fetchFromGitHub +, fetchpatch +, cmake +, pkg-config +, mongoc +, openssl +, darwin +}: + stdenv.mkDerivation rec { pname = "libmongocrypt"; version = "1.7.4"; @@ -20,7 +30,12 @@ stdenv.mkDerivation rec { ]; nativeBuildInputs = [ cmake pkg-config ]; - buildInputs = [ mongoc openssl ]; + buildInputs = [ + mongoc + openssl + ] ++ lib.optionals stdenv.isDarwin [ + darwin.apple_sdk.frameworks.Security + ]; cmakeFlags = [ # all three of these are required to use system libbson