From 857507f690c411269f66df74ecc18c8a6d06c4d2 Mon Sep 17 00:00:00 2001 From: Tristan Date: Sat, 13 Nov 2021 20:04:15 -0500 Subject: [PATCH] freeimage: fix build on aarch64-darwin (#145785) --- pkgs/development/libraries/freeimage/default.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkgs/development/libraries/freeimage/default.nix b/pkgs/development/libraries/freeimage/default.nix index 87997cead43f..2b4b174ca31b 100644 --- a/pkgs/development/libraries/freeimage/default.nix +++ b/pkgs/development/libraries/freeimage/default.nix @@ -24,6 +24,9 @@ stdenv.mkDerivation { --replace "pkg-config" "$PKG_CONFIG" substituteInPlace Makefile.gnu \ --replace "pkg-config" "$PKG_CONFIG" + '' + lib.optionalString (stdenv.isDarwin && stdenv.isAarch64) '' + # Upstream Makefile hardcodes i386 and x86_64 architectures only + substituteInPlace Makefile.osx --replace "x86_64" "arm64" ''; nativeBuildInputs = [