···5858 # calls install-strip ...
5959 dontBuild = true;
60606161- # The binaries for Darwin use frameworks, so fake those frameworks,
6262- # and create some wrapper scripts that set DYLD_FRAMEWORK_PATH so
6363- # that the executables work with no special setup.
6461 postInstall =
6565- (if stdenv.isDarwin then
6666- ''
6767- mkdir -p $out/frameworks/GMP.framework/Versions/A
6868- ln -s ${gmp.out}/lib/libgmp.dylib $out/frameworks/GMP.framework/GMP
6969- ln -s ${gmp.out}/lib/libgmp.dylib $out/frameworks/GMP.framework/Versions/A/GMP
7070- # !!! fix this
7171- mkdir -p $out/frameworks/GNUeditline.framework/Versions/A
7272- ln -s ${libedit}/lib/libeditline.dylib $out/frameworks/GNUeditline.framework/GNUeditline
7373- ln -s ${libedit}/lib/libeditline.dylib $out/frameworks/GNUeditline.framework/Versions/A/GNUeditline
7474-7575- mv $out/bin $out/bin-orig
7676- mkdir $out/bin
7777- for i in $(cd $out/bin-orig && ls); do
7878- echo \"#! $SHELL -e\" >> $out/bin/$i
7979- echo \"DYLD_FRAMEWORK_PATH=$out/frameworks exec $out/bin-orig/$i -framework-path $out/frameworks \\\"\\$@\\\"\" >> $out/bin/$i
8080- chmod +x $out/bin/$i
8181- done
8282- '' else "")
8383- +
8462 ''
8563 # bah, the passing gmp doesn't work, so let's add it to the final package.conf in a quick but dirty way
8664 sed -i "s@^\(.*pkgName = PackageName \"rts\".*\libraryDirs = \\[\)\(.*\)@\\1\"${gmp.out}/lib\",\2@" $out/lib/ghc-${version}/package.conf