Skip to content

Commit 45ef494

Browse files
committed
Attempt to get CUDA available for build
1 parent c7dfa37 commit 45ef494

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

T/Torch/TorchCUDA/build_tarballs.jl

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,9 @@ products = [
5858
LibraryProduct("libtorch", :libtorch, dont_dlopen = true),
5959
]
6060

61-
dependencies = [Dependency(PackageSpec(name="CUDA_loader_jll"))]
61+
dependencies = [
62+
Dependency("CUDA_loader_jll")
63+
]
6264

6365
cuda_versions = [v"10.2", v"11.0", v"11.1", v"11.2", v"11.3", v"11.4", v"11.5", v"11.6"]
6466
for cuda_version in cuda_versions
@@ -72,8 +74,9 @@ for cuda_version in cuda_versions
7274
for platform in platforms
7375
augmented_platform = Platform(arch(platform), os(platform); cuda=cuda_tag)
7476
should_build_platform(triplet(augmented_platform)) || continue
77+
platform_dependencies = vcat(dependencies, [BuildDependency(PackageSpec("CUDA_jll", Base.UUID("e9e359dc-d701-5aa8-82ae-09bbf812ea83"), cuda_version))])
7578
build_tarballs(ARGS, name, version, sources, script, [augmented_platform],
76-
products, dependencies; lazy_artifacts=true,
79+
products, platform_dependencies; lazy_artifacts=true,
7780
preferred_gcc_version = v"7.1.0")
7881
end
7982
end

0 commit comments

Comments
 (0)