multi system flake

This commit is contained in:
Osman Faruk Bayram 2025-10-23 13:52:41 +03:00
parent c61e5d2c69
commit ccdc188234

View file

@ -7,22 +7,29 @@
gradle-dot-nix.url = "github:CrazyChaoz/gradle-dot-nix"; gradle-dot-nix.url = "github:CrazyChaoz/gradle-dot-nix";
}; };
outputs = outputs =
inputs: inputs@{ nixpkgs, android-nixpkgs, gradle2nix, gradle-dot-nix, ... }:
let let
system = "x86_64-linux"; supportedSystems = [
pkgs = import inputs.nixpkgs { "x86_64-linux"
inherit system; "aarch64-linux"
config = { "x86_64-darwin"
allowUnfree = true; "aarch64-darwin"
];
android_sdk.accept_license = true; forAllSystems = f: nixpkgs.lib.genAttrs supportedSystems (system: f system);
};
};
myLib = pkgs.callPackage ./lib { inherit inputs; };
in in
{ {
packages.x86_64-linux = myLib.byNameOverlay ./apks; packages = forAllSystems (system:
lib = myLib; let
pkgs = import nixpkgs {
inherit system;
config = {
allowUnfree = true;
android_sdk.accept_license = true;
};
};
myLib = pkgs.callPackage ./lib { inherit inputs; };
in
myLib.byNameOverlay ./apks
);
}; };
} }