From b1f07e88a3c5394859cad0f8fbefde49ae5b7315 Mon Sep 17 00:00:00 2001 From: Vinzenz Schroeter Date: Thu, 28 Nov 2024 18:33:10 +0100 Subject: [PATCH 1/2] use default features of font loader on macos --- Cargo.toml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 46896ed..867a007 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -24,7 +24,11 @@ version = "0.30" features = ["rwh_05"] default-features = true -[dependencies.font-kit] +[target.'cfg(target_os = "linux")'.dependencies.font-kit] version = "0.14.2" features = ["loader-freetype-default", "source-fontconfig-dlopen"] default-features = false + +[target.'cfg(target_os = "macos")'.dependencies.font-kit] +version = "0.14.2" +default-features = true From 8387565d9b583ed7bad479dcdc0f323a4be5fd04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Ha=CC=88cker?= Date: Thu, 28 Nov 2024 19:36:58 +0100 Subject: [PATCH 2/2] Add mac dependencies --- flake.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/flake.nix b/flake.nix index d528014..d1d2542 100644 --- a/flake.nix +++ b/flake.nix @@ -88,6 +88,14 @@ xorg.libX11 xorg.libX11.dev ] + )) + ++ (lib.optionals pkgs.stdenv.isDarwin ( + with pkgs.darwin.apple_sdk.frameworks; + [ + Carbon + QuartzCore + AppKit + ] )); postInstall = ''