From d4f176f70dedf0671a5d24514fefa8c8986a501c Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Sun, 31 May 2015 18:00:33 -0700 Subject: [PATCH] Fix libiconv handling when using a crossSystem --- pkgs/top-level/all-packages.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1609c6fac7e4..2cd659a5e75f 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6871,8 +6871,11 @@ let # glibc provides libiconv so systems with glibc don't need to build libiconv # separately, but we also provide libiconvReal, which will always be a # standalone libiconv, just in case you want it - libiconv = - if stdenv.isGlibc then stdenv.cc.libc + libiconv = if crossSystem != null then + (if crossSystem.libc == "glibc" then libcCross + else if crossSystem.libc == "libSystem" then darwin.libiconv + else libiconvReal) + else if stdenv.isGlibc then stdenv.cc.libc else if stdenv.isDarwin then darwin.libiconv else libiconvReal;