nixpkgs/pkgs/by-name/bu/bundletool/package.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

39 lines
1.1 KiB
Nix
Raw Normal View History

{
lib,
stdenvNoCC,
fetchurl,
makeBinaryWrapper,
jre_headless,
}:
2022-07-26 04:20:00 +00:00
stdenvNoCC.mkDerivation (finalAttrs: {
2022-07-26 04:20:00 +00:00
pname = "bundletool";
2024-10-23 02:28:53 +00:00
version = "1.17.2";
2022-07-26 04:20:00 +00:00
src = fetchurl {
url = "https://github.com/google/bundletool/releases/download/${finalAttrs.version}/bundletool-all-${finalAttrs.version}.jar";
2024-10-23 02:28:53 +00:00
sha256 = "sha256-LUrZCPrqZAR8HMnLdH5qpmfGqxkuCWB70WtnJGqM1q4=";
2022-07-26 04:20:00 +00:00
};
dontUnpack = true;
nativeBuildInputs = [ makeBinaryWrapper ];
installPhase = ''
runHook preInstall
makeWrapper ${jre_headless}/bin/java $out/bin/bundletool --add-flags "-jar $src"
runHook postInstall
'';
meta = {
2022-07-26 04:20:00 +00:00
description = "Command-line tool to manipulate Android App Bundles";
mainProgram = "bundletool";
2022-07-26 04:20:00 +00:00
homepage = "https://developer.android.com/studio/command-line/bundletool";
changelog = "https://github.com/google/bundletool/releases/tag/${finalAttrs.version}";
sourceProvenance = with lib.sourceTypes; [ binaryBytecode ];
maintainers = with lib.maintainers; [ momeemt ];
2022-07-26 04:20:00 +00:00
platforms = jre_headless.meta.platforms;
license = lib.licenses.asl20;
2022-07-26 04:20:00 +00:00
};
})