blob: 2c3928b0bd02e0a07e74be38c83f4f26961015db [file] [log] [blame]
Skyler Turner784b7a02022-03-02 10:38:32 +00001{
2 description = "A flake to build android's partition-tools package";
3
4 inputs.nixpkgs.url = github:NixOS/nixpkgs/nixos-21.11;
5
6 inputs.src.url = github:AndroidDumps/Firmware_extractor;
7 inputs.src.flake = false;
8
9 outputs = { self, nixpkgs, src }: {
10
11 packages.x86_64-linux.partition-tools =
12 with import nixpkgs { system = "x86_64-linux"; };
13 stdenv.mkDerivation {
14 inherit src;
15 name = "partition-tools";
16 installPhase = "mkdir -p $out/bin && cp ${src}/tools/Linux/bin/* $out/bin && cp ${src}/tools/Linux/bin/bin/* $out/bin";
17 };
18
19 defaultPackage.x86_64-linux = self.packages.x86_64-linux.partition-tools;
20
21 };
22}