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