Skip to content
This repository was archived by the owner on Apr 6, 2026. It is now read-only.

Commit b590c3f

Browse files
committed
Cache extra ROCm/XPU build dependencies
1 parent 0b7e009 commit b590c3f

2 files changed

Lines changed: 12 additions & 0 deletions

File tree

flake.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,7 @@
146146
with buildSet.pkgs;
147147
(
148148
allOutputs buildSet.torch
149+
++ lib.concatMap allOutputs buildSet.extension.extraBuildDeps
149150
++ allOutputs build2cmake
150151
++ allOutputs kernel-abi-check
151152
++ allOutputs python3Packages.kernels

lib/torch-extension/default.nix

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
{
2+
rocmSupport ? torch.rocmSupport,
3+
xpuSupport ? torch.xpuSupport,
4+
5+
lib,
26
callPackage,
37
stdenv,
48
stdenvGlibc_2_27,
@@ -31,6 +35,13 @@ let
3135
};
3236
in
3337
{
38+
extraBuildDeps =
39+
lib.optionals xpuSupport [
40+
oneapi-torch-dev
41+
onednn-xpu
42+
]
43+
++ lib.optionals rocmSupport [ clr ];
44+
3445
mkExtension = callPackage ./arch.nix {
3546
inherit
3647
clr

0 commit comments

Comments
 (0)