git.iko.soy/typeable/nixpkgs
on master help sign in
mlton: fix build with clang (darwin)

A minor tweak is necessary to avoid raising an error when building with clang. This gets mlton building on darwin.

commit7181d20a4f0e2f2d16d349a4ae151e7814e30d63 authorAnthony Cowley <acowley@gmail.com> dateThu 22 Sep 2016, 23:02 (10 years ago) parentcdec20a
1 file changed+2
pkgs/development/compilers/mlton/default.nix+2
pkgs/development/compilers/mlton/default.nix+2
@@ -61,6 +61,8 @@ stdenv.mkDerivation rec {
6161 done
6262
6363 substituteInPlace $(pwd)/../${usr_prefix}/bin/mlton --replace '/${usr_prefix}/lib/mlton' $(pwd)/../${usr_prefix}/lib/mlton
64+ '' + stdenv.lib.optionalString stdenv.cc.isClang ''
65+ sed -i "s_ patch -s -p0 <gdtoa.hide-public-fns.patch_ patch -s -p0 <gdtoa.hide-public-fns.patch\n\tsed -i 's|printf(emptyfmt|printf(\"\"|g' ./gdtoa/arithchk.c_" ./runtime/Makefile
6466 '';
6567
6668 preBuild = ''