on master help sign in
nix-bundle/release.nix
34 lines 994 B history raw
1{ nixpkgs ? <nixpkgs>
2, nixpkgs' ? import nixpkgs {}}: with nixpkgs';
4stdenv.mkDerivation rec {
5 pname = "nix-bundle";
6 name = "${pname}-${version}";
7 version = "0.4.0";
9 src = ./.;
11 # coreutils, gnutar is actually needed by nix for bootstrap
12 buildInputs = [ nix coreutils makeWrapper gnutar gzip bzip2 ];
14 nixBundlePath = lib.makeBinPath [ nix coreutils gnutar gzip bzip2 ];
15 nixRunPath = lib.makeBinPath [ nix coreutils ];
17 makeFlags = [ "PREFIX=$(out)" ];
19 postInstall = ''
20 mkdir -p $out/bin
21 makeWrapper $out/share/nix-bundle/nix-bundle.sh $out/bin/nix-bundle \
22 --prefix PATH : ${nixBundlePath}
23 makeWrapper $out/share/nix-bundle/nix-run.sh $out/bin/nix-run \
24 --prefix PATH : ${nixRunPath}
25 '';
27 meta = with lib; {
28 maintainers = [ maintainers.matthewbauer ];
29 platforms = platforms.all;
30 description = "Create bundles from Nixpkgs attributes";
31 license = licenses.mit;
32 homepage = https://github.com/matthewbauer/nix-bundle;
33 };