nixpkgs/pkgs/development/idris-modules/with-packages.nix
Matthew Bauer a0f4d19925 treewide: use appendToName where appropriate
Using appendToName preserves the version at the end of the name.
2018-05-25 15:48:31 -05:00

21 lines
459 B
Nix

# Build a version of idris with a set of packages visible
# packages: The packages visible to idris
{ stdenv, idris, symlinkJoin, makeWrapper }: packages:
let paths = stdenv.lib.closePropagation packages;
in
stdenv.lib.appendToName "with-packages" (symlinkJoin {
inherit (idris) name;
paths = paths ++ [idris] ;
buildInputs = [ makeWrapper ];
postBuild = ''
wrapProgram $out/bin/idris \
--set IDRIS_LIBRARY_PATH $out/libs
'';
})