diff options
Diffstat (limited to 'nixpkgs/pkgs/development/compilers/mlton/20180207-binary.nix')
-rw-r--r-- | nixpkgs/pkgs/development/compilers/mlton/20180207-binary.nix | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/nixpkgs/pkgs/development/compilers/mlton/20180207-binary.nix b/nixpkgs/pkgs/development/compilers/mlton/20180207-binary.nix index 2b4998f91c91..4846b58bf26b 100644 --- a/nixpkgs/pkgs/development/compilers/mlton/20180207-binary.nix +++ b/nixpkgs/pkgs/development/compilers/mlton/20180207-binary.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, patchelf, gmp }: +{ lib, stdenv, fetchurl, patchelf, gmp }: let dynamic-linker = stdenv.cc.bintools.dynamicLinker; in @@ -18,7 +18,7 @@ stdenv.mkDerivation rec { throw "Architecture not supported"; buildInputs = [ gmp ]; - nativeBuildInputs = stdenv.lib.optional stdenv.isLinux patchelf; + nativeBuildInputs = lib.optional stdenv.isLinux patchelf; buildPhase = '' make update \ @@ -31,7 +31,7 @@ stdenv.mkDerivation rec { make install PREFIX=$out ''; - postFixup = stdenv.lib.optionalString stdenv.isLinux '' + postFixup = lib.optionalString stdenv.isLinux '' patchelf --set-interpreter ${dynamic-linker} $out/lib/mlton/mlton-compile patchelf --set-rpath ${gmp}/lib $out/lib/mlton/mlton-compile @@ -39,7 +39,7 @@ stdenv.mkDerivation rec { patchelf --set-interpreter ${dynamic-linker} $out/bin/$e patchelf --set-rpath ${gmp}/lib $out/bin/$e done - '' + stdenv.lib.optionalString stdenv.isDarwin '' + '' + lib.optionalString stdenv.isDarwin '' install_name_tool -change \ /opt/local/lib/libgmp.10.dylib \ ${gmp}/lib/libgmp.10.dylib \ |