libiconv: use libiconvReal on Darwin with compat ABI

This commit is contained in:
Randy Eckenrode 2024-03-27 17:09:25 -04:00
parent 2944f24f12
commit 33dc78e7e0
No known key found for this signature in database
GPG Key ID: 64C1CD4EC2A600D9
1 changed files with 3 additions and 3 deletions

View File

@ -22711,7 +22711,7 @@ with pkgs;
# GNU libc provides libiconv so systems with glibc don't need to
# build libiconv separately. Additionally, Apple forked/repackaged
# libiconv so we use that instead of the vanilla version on that OS,
# libiconv, so build and use the upstream one with a compatible ABI,
# and BSDs include libiconv in libc.
#
# We also provide `libiconvReal`, which will always be a standalone libiconv,
@ -22722,7 +22722,7 @@ with pkgs;
then libcCross
else stdenv.cc.libc)
else if stdenv.hostPlatform.isDarwin
then darwin.libiconv
then libiconvReal.override { enableDarwinABICompat = true; }
else libiconvReal;
libcIconv = libc: let
@ -22739,7 +22739,7 @@ with pkgs;
if lib.elem stdenv.hostPlatform.libc [ "glibc" "musl" ] then
lib.getBin stdenv.cc.libc
else if stdenv.hostPlatform.isDarwin then
lib.getBin darwin.libiconv
lib.getBin libiconv
else
lib.getBin libiconvReal;