@@ -26,6 +26,15 @@ stdenv.mkDerivation rec {
2626 # to the bootstrap-tools libgcc (as uses to happen on arm/mips)
2727 NIX_CFLAGS_COMPILE = stdenv.lib.optionalString (!stdenv.isDarwin) "-static-libgcc";
2828
29+ postInstall = stdenv.lib.optionalString stdenv.isDarwin ''
30+ # jww (2015-01-06): Sometimes this library install as a .so, even on
31+ # Darwin; others time it installs as a .dylib. I haven't yet figured out
32+ # what causes this difference.
33+ for file in $out/lib/*.so* $out/lib/*.dylib* ; do
34+ install_name_tool -id "$file" $file
35+ done
36+ '';
37+
2938 crossAttrs = {
3039 dontStrip = static;
3140 } // stdenv.lib.optionalAttrs (stdenv.cross.libc == "msvcrt") {