2018-01-10 02:38:19 +03:00
|
|
|
{ stdenvNoCC, gx, gx-go, go, cacert }:
|
2016-10-29 06:17:27 +03:00
|
|
|
|
|
|
|
{ name, src, sha256 }:
|
|
|
|
|
2018-01-10 02:38:19 +03:00
|
|
|
stdenvNoCC.mkDerivation {
|
2016-10-29 06:17:27 +03:00
|
|
|
name = "${name}-gxdeps";
|
|
|
|
inherit src;
|
|
|
|
|
2018-01-14 22:18:27 +03:00
|
|
|
nativeBuildInputs = [ cacert go gx gx-go ];
|
2016-10-29 06:17:27 +03:00
|
|
|
|
|
|
|
outputHashAlgo = "sha256";
|
|
|
|
outputHashMode = "recursive";
|
|
|
|
outputHash = sha256;
|
|
|
|
|
|
|
|
phases = [ "unpackPhase" "buildPhase" "installPhase" ];
|
|
|
|
|
|
|
|
buildPhase = ''
|
|
|
|
export GOPATH=$(pwd)/vendor
|
2017-03-21 16:25:49 +03:00
|
|
|
mkdir -p vendor
|
2016-10-29 06:17:27 +03:00
|
|
|
gx install
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mv vendor $out
|
|
|
|
'';
|
|
|
|
|
|
|
|
preferLocalBuild = true;
|
|
|
|
}
|