/
flake.nix
42 lines (40 loc) · 1.38 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
{
description = "Triton inference server ONNX runtime backend";
inputs.flake-utils.url = "github:numtide/flake-utils";
inputs.onnxruntime = {
url = "https://github.com/microsoft/onnxruntime.git";
flake = false;
type = "git";
submodules = true;
};
inputs.onnxruntime-backend = {
url = "github:triton-inference-server/onnxruntime_backend";
flake = false;
};
inputs.repo-common = {
url = "github:triton-inference-server/common";
flake = false;
};
inputs.repo-core = {
url = "github:triton-inference-server/core";
flake = false;
};
inputs.repo-backend = {
url = "github:triton-inference-server/backend";
flake = false;
};
outputs = { self, nixpkgs, flake-utils, ... }@inputs: flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
pkgsUnfree = import nixpkgs { inherit system; config.allowUnfree = true; };
onnxruntime = with pkgsUnfree; callPackage ./onnxruntime/default.nix { inherit (inputs) onnxruntime; };
onnxruntime-backend = with pkgsUnfree; callPackage ./onnxruntime_backend/default.nix {
inherit (inputs) onnxruntime-backend repo-core repo-common repo-backend;
microsoft-onnxruntime = onnxruntime;
};
in rec {
packages.onnxruntime = onnxruntime;
packages.onnxruntime-backend = onnxruntime-backend;
defaultPackage = packages.onnxruntime-backend;
});
}