git.iko.soy/typeable/nixpkgs
on master help sign in
pyre: simplify build phases
commit3d444cfd8e0a02f5854104c06cbcc0f6905ae6a8 authorJörg Thalheim <joerg@thalheim.io> dateMon 3 Dec 2018, 08:19 (8 years ago) parent92cba3a
1 file changed+8−11
pkgs/development/tools/pyre/default.nix+8−11
pkgs/development/tools/pyre/default.nix+8−11
@@ -44,32 +44,29 @@ let
4444 # python36Packages.python36Full # TODO
4545 ];
4646
47− buildPhase = ''
47+ preBuild = ''
4848 # build requires HOME to be set
49− export HOME=.
49+ export HOME=$TMPDIR
5050
5151 # "external" because https://github.com/facebook/pyre-check/pull/8/files
5252 sed "s/%VERSION%/external/" dune.in > dune
5353
54− cp ${versionFile} ./scripts/generate-version-number.sh
54+ ln -sf ${versionFile} ./scripts/generate-version-number.sh
5555
5656 mkdir $(pwd)/build
5757 export OCAMLFIND_DESTDIR=$(pwd)/build
5858 export OCAMLPATH=$OCAMLPATH:$(pwd)/build
59−
60− make release
6159 '';
6260
63− checkPhase = ''
64− make test
65− # ./scripts/run-python-tests.sh # TODO: once typeshed and python bits are added
66− '';
61+ buildFlags = [ "release" ];
62+
63+ doCheck = true;
64+ # ./scripts/run-python-tests.sh # TODO: once typeshed and python bits are added
6765
6866 # Note that we're not installing the typeshed yet.
6967 # Improvement for a future version.
7068 installPhase = ''
71− mkdir -p $out/bin
72− cp ./_build/default/main.exe $out/bin/pyre.bin
69+ install -D ./_build/default/main.exe $out/bin/pyre.bin
7370 '';
7471
7572 meta = with stdenv.lib; {