-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathflake.nix
51 lines (45 loc) · 1.8 KB
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{
description = "nix-alien";
inputs = {
flake-compat.url = "github:edolstra/flake-compat";
flake-utils.url = "github:numtide/flake-utils";
nix-filter.url = "github:numtide/nix-filter";
nix-index-database = {
url = "github:nix-community/nix-index-database";
inputs.nixpkgs.follows = "nixpkgs";
};
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
};
outputs = { self, nixpkgs, flake-utils, ... }:
{
overlays.default = final: prev: import ./overlay.nix { inherit self final prev; };
# Integration tests are only available in x86_64-linux for now
integration-tests.x86_64-linux = import ./integration-tests.nix { inherit self; };
} // (flake-utils.lib.eachSystem [ "aarch64-linux" "x86_64-linux" ] (system:
let
pkgs = import nixpkgs {
inherit system;
overlays = [ self.overlays.default ];
};
in
{
formatter = pkgs.nixpkgs-fmt;
packages = {
inherit (pkgs) nix-alien nix-index-update;
default = self.outputs.packages.${system}.nix-alien;
};
checks = import ./checks.nix { inherit pkgs self; };
apps =
let
inherit (flake-utils.lib) mkApp;
in
{
default = self.outputs.apps.${system}.nix-alien;
nix-alien = mkApp { drv = self.outputs.packages.${system}.nix-alien; };
nix-alien-ld = mkApp { drv = self.outputs.packages.${system}.nix-alien; name = "nix-alien-ld"; };
nix-alien-find-libs = mkApp { drv = self.outputs.packages.${system}.nix-alien; name = "nix-alien-find-libs"; };
nix-index-update = mkApp { drv = self.outputs.packages.${system}.nix-index-update; };
};
devShells.default = import ./shell.nix { inherit pkgs self; };
}));
}