-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathflake.nix
35 lines (31 loc) · 953 Bytes
/
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
{
description = "provides the libvfn package for NixOS and Nix environments";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
};
outputs = { self, nixpkgs }:
let
libvfnVersion = "5.1.0";
# lists supported systems
allSystems = [ "x86_64-linux" "aarch64-linux" ];
forAllSystems = fn:
nixpkgs.lib.genAttrs allSystems
(system: fn { pkgs = import nixpkgs { inherit system; }; });
in {
formatter = forAllSystems ({ pkgs }: pkgs.nixfmt);
packages = forAllSystems ({ pkgs }: rec {
libvfn = pkgs.stdenv.mkDerivation {
pname = "libvfn";
version = libvfnVersion;
src = ./.;
mesonFlags = [
"-Ddocs=disabled"
"-Dlibnvme=disabled"
"-Dprofiling=false"
];
nativeBuildInputs = with pkgs; [ meson ninja pkg-config perl ];
};
default = libvfn;
});
};
}