summary refs log tree commit diff
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2018-01-28 22:17:04 -0500
committerJohn Ericson <John.Ericson@Obsidian.Systems>2018-01-29 00:47:02 -0500
commit82ebace595bd3de93b697681180fa13e4fd6b491 (patch)
treea012babe5e8d20c5946f2c8323f985e3dc1b8791
parente2a54266c411e71bb5e65d9523766782728a1c3f (diff)
downloadnixpkgs-82ebace595bd3de93b697681180fa13e4fd6b491.tar
nixpkgs-82ebace595bd3de93b697681180fa13e4fd6b491.tar.gz
nixpkgs-82ebace595bd3de93b697681180fa13e4fd6b491.tar.bz2
nixpkgs-82ebace595bd3de93b697681180fa13e4fd6b491.tar.lz
nixpkgs-82ebace595bd3de93b697681180fa13e4fd6b491.tar.xz
nixpkgs-82ebace595bd3de93b697681180fa13e4fd6b491.tar.zst
nixpkgs-82ebace595bd3de93b697681180fa13e4fd6b491.zip
glibc: Fix Darwin build
Fix the failure caused in #34198 by a suggested change of mine. @vcunat
reported in [1].

[1]: https://github.com/NixOS/nixpkgs/pull/34198#issuecomment-361075911
-rw-r--r--pkgs/development/libraries/glib/default.nix4
1 files changed, 3 insertions, 1 deletions
diff --git a/pkgs/development/libraries/glib/default.nix b/pkgs/development/libraries/glib/default.nix
index 656cdffbb4c..f68bd138005 100644
--- a/pkgs/development/libraries/glib/default.nix
+++ b/pkgs/development/libraries/glib/default.nix
@@ -75,7 +75,9 @@ stdenv.mkDerivation rec {
   # internal pcre would only add <200kB, but it's relatively common
   configureFlags = [ "--with-pcre=system" ]
     ++ optional stdenv.isDarwin "--disable-compile-warnings"
-    ++ optional (stdenv.hostPlatform.libc != "glibc") "--with-libiconv=gnu"
+    # glibc inclues GNU libiconv, but Darwin's iconv function is good enonugh.
+    ++ optional (stdenv.hostPlatform.libc != "glibc" && !stdenv.hostPlatform.isDarwin)
+      "--with-libiconv=gnu"
     ++ optional stdenv.isSunOS "--disable-dtrace"
     # Can't run this test when cross-compiling
     ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform)