@@ -1,14 +1,14 @@
1{ stdenv, fetchFromGitHub, jdk, ant, python2, python2Packages, watchman, bash, makeWrapper }:
1{ stdenv, fetchFromGitHub, jdk, ant, python2, python2Packages, watchman, bash, makeWrapper }:
3stdenv.mkDerivation rec {
3stdenv.mkDerivation rec {
4− name = "buck-${version}";
4+ pname = "buck";
5− version = "2017.10.01.01";
5+ version = "2019.01.10.01";
7 src = fetchFromGitHub {
7 src = fetchFromGitHub {
8 owner = "facebook";
8 owner = "facebook";
9− repo = "buck";
9+ repo = pname;
10 rev = "v${version}";
10 rev = "v${version}";
11− sha256 = "05nyyb6f0hv1h67zzvdq8297yl8zjhpbasx35lxnrsjz0m1h8ngw";
11+ sha256 = "0987s399v4ba2a3crca12vsg9001xcb5drhqi564ninpa5vxamr2";
14 patches = [ ./pex-mtime.patch ];
14 patches = [ ./pex-mtime.patch ];
@@ -20,23 +20,17 @@ stdenv.mkDerivation rec {
20 buildInputs = [ jdk ant python2 watchman python2Packages.pywatchman ];
20 buildInputs = [ jdk ant python2 watchman python2Packages.pywatchman ];
21 nativeBuildInputs = [ makeWrapper ];
21 nativeBuildInputs = [ makeWrapper ];
23− targets = [ "buck" "buckd" ];
25 buildPhase = ''
23 buildPhase = ''
28− for exe in ${toString targets}; do
26+ ./bin/buck build -c buck.release_version=${version} buck
29− ./bin/buck build //programs:$exe
33 installPhase = ''
29 installPhase = ''
34− for exe in ${toString targets}; do
35− install -D -m755 buck-out/gen/programs/$exe.pex $out/bin/$exe
30+ install -D -m755 buck-out/gen/programs/buck.pex $out/bin/buck
36− wrapProgram $out/bin/$exe \
31+ wrapProgram $out/bin/buck \
37− --prefix PYTHONPATH : $PYTHONPATH \
32+ --prefix PYTHONPATH : $PYTHONPATH \
38− --prefix PATH : "${stdenv.lib.makeBinPath [jdk watchman]}"
33+ --prefix PATH : "${stdenv.lib.makeBinPath [jdk watchman]}"
42 meta = with stdenv.lib; {
36 meta = with stdenv.lib; {