elixir: make curl available to mix

This commit is contained in:
Tino Breddin 2014-09-27 21:58:58 +02:00
parent 7323d5e128
commit cba717fd7b

View File

@ -1,4 +1,4 @@
{ stdenv, fetchurl, erlang, rebar, makeWrapper, coreutils }: { stdenv, fetchurl, erlang, rebar, makeWrapper, coreutils, curl, bash, cacert }:
let let
version = "1.0.0"; version = "1.0.0";
@ -20,6 +20,8 @@ stdenv.mkDerivation {
substituteInPlace Makefile \ substituteInPlace Makefile \
--replace "/usr/local" $out --replace "/usr/local" $out
substituteInPlace bin//mix \
--replace "/usr/bin/env elixir" "$out/bin/elixir"
''; '';
postFixup = '' postFixup = ''
@ -29,7 +31,8 @@ stdenv.mkDerivation {
for f in $out/bin/* for f in $out/bin/*
do do
wrapProgram $f \ wrapProgram $f \
--prefix PATH ":" "${erlang}/bin:${coreutils}/bin" --prefix PATH ":" "${erlang}/bin:${coreutils}/bin:${curl}/bin:${bash}/bin" \
--set CURL_CA_BUNDLE "${cacert}/etc/ca-bundle.crt"
done done
''; '';