28 lines
724 B
Nix
28 lines
724 B
Nix
{ system ? builtins.currentSystem, git_version ? "unknown", }:
|
|
|
|
with import ./nix/common.nix;
|
|
|
|
let
|
|
pkgs = import nixpkgs { };
|
|
compile = import ./nix/compile.nix;
|
|
|
|
compileWith = args: compile ({
|
|
inherit system git_version nixpkgs;
|
|
crane = flake.inputs.crane;
|
|
rust-overlay = flake.inputs.rust-overlay;
|
|
} // args);
|
|
|
|
build_release = target: (compile {
|
|
inherit target;
|
|
release = true;
|
|
}).garage;
|
|
|
|
in {
|
|
releasePackages = {
|
|
amd64 = build_release "x86_64-unknown-linux-musl";
|
|
i386 = build_release "i686-unknown-linux-musl";
|
|
arm64 = build_release "aarch64-unknown-linux-musl";
|
|
arm = build_release "armv6l-unknown-linux-musleabihf";
|
|
};
|
|
flakePackages = flake.packages.${system};
|
|
}
|