From 5e7ab63708082da007fd6e3bb56df3baddc93cdf Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 13 Jan 2023 15:49:26 -0500 Subject: [PATCH 01/40] Adding cuda-cudart --- recipes/cuda-cudart/bld.bat | 17 ++++++++ recipes/cuda-cudart/build.sh | 24 +++++++++++ recipes/cuda-cudart/meta.yaml | 76 +++++++++++++++++++++++++++++++++++ 3 files changed, 117 insertions(+) create mode 100644 recipes/cuda-cudart/bld.bat create mode 100644 recipes/cuda-cudart/build.sh create mode 100644 recipes/cuda-cudart/meta.yaml diff --git a/recipes/cuda-cudart/bld.bat b/recipes/cuda-cudart/bld.bat new file mode 100644 index 0000000000000..6af6c302f87a4 --- /dev/null +++ b/recipes/cuda-cudart/bld.bat @@ -0,0 +1,17 @@ +if not exist %PREFIX% mkdir %PREFIX% + +rem Directories... +for /D %%i in (.\*) do ( + robocopy /E %%i %PREFIX%\%%i +) + +rem Files... +for %%i in (.\*) do ( + if not %%~ni==build_env_setup ( + if not %%~ni==conda_build ( + if not %%~ni==metadata_conda_debug ( + xcopy %%i %PREFIX% + ) + ) + ) +) diff --git a/recipes/cuda-cudart/build.sh b/recipes/cuda-cudart/build.sh new file mode 100644 index 0000000000000..88d88e1c61295 --- /dev/null +++ b/recipes/cuda-cudart/build.sh @@ -0,0 +1,24 @@ +#!/bin/bash + +# Install to conda style directories +[[ -d lib64 ]] && mv lib64 lib + +[[ ${target_platform} == "linux-64" ]] && targetsDir="targets/x86_64-linux" +[[ ${target_platform} == "linux-ppc64le" ]] && targetsDir="targets/ppc64le-linux" +[[ ${target_platform} == "linux-aarch64" ]] && targetsDir="targets/sbsa-linux" + +for i in `ls`; do + [[ $i == "build_env_setup.sh" ]] && continue + [[ $i == "conda_build.sh" ]] && continue + [[ $i == "metadata_conda_debug.yaml" ]] && continue + if [[ $i == "lib" ]] || [[ $i == "include" ]]; then + mkdir -p ${PREFIX}/${targetsDir} + mkdir -p ${PREFIX}/$i + cp -rv $i ${PREFIX}/${targetsDir} + for j in `ls $i`; do + ln -s ../${targetsDir}/$i/$j ${PREFIX}/$i/$j + done + else + cp -rv $i ${PREFIX} + fi +done diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml new file mode 100644 index 0000000000000..835dead2b06e2 --- /dev/null +++ b/recipes/cuda-cudart/meta.yaml @@ -0,0 +1,76 @@ +{% set name = "cuda-cudart" %} +{% set version = "12.0.107" %} +{% set platform = "linux-x86_64" %} # [linux64] +{% set platform = "linux-ppc64le" %} # [ppc64le] +{% set platform = "linux-sbsa" %} # [aarch64] +{% set platform = "windows-x86_64" %} # [win] +{% set extension = "tar.xz" %} # [not win] +{% set extension = "zip" %} # [win] + +package: + name: {{ name|lower }} + version: {{ version }} + +source: + url: https://developer.download.nvidia.com/compute/cuda/redist/cuda_cudart/{{ platform }}/cuda_cudart-{{ platform }}-{{ version }}-archive.{{ extension }} + sha256: c0e16e9593a69afe4997ae96a8b024e751ebce0254523fd969b08bb028582d23 # [linux64] + sha256: d785fd613e35e3761fdb0016a31a56417f570605cbfb9a93ca9dc68be6789188 # [ppc64le] + sha256: 5de248c6c203f6c91ce34256bbfc028bc87c1b0c552f9f51edb65e60ad665f63 # [aarch64] + sha256: 1cd8516feee068c6d718453e76b0dfcbee27844a35d4f3aa608a3d316190309c # [win] + +build: + number: 0 + skip: true # [osx] + run_exports: + strong: + - __glibc >=2.17 # [linux] + +requirements: + build: + - {{ compiler("c") }} + - {{ compiler("cxx") }} + host: + - sysroot_{{ target_platform }} 2.17 # [linux] + - __glibc >=2.17 # [linux] + run: + - sysroot_{{ target_platform }} 2.17 # [linux] + - __glibc >=2.17 # [linux] + +outputs: + - name: cuda-cudart + files: + - lib/*.so.* + - targets/*/lib/*.so.* + + - name: cuda-cudart-dev + requirements: + run: + - cuda-cudart >={{ version }} + files: + - lib/*.so + - targets/*/lib/*.so + - include + + - name: cuda-cudart-static + requirements: + run: + - cuda-cudart-dev >={{ version }} + files: + - lib/*.a + - targets/*/lib/*.a + + - name: cuda-driver-dev + files: + - lib/stubs/libcuda.so + - targets/*/lib/stubs/libcuda.so + +about: + home: https://developer.nvidia.com/cuda-toolkit + license_url: https://docs.nvidia.com/cuda/eula/index.html + description: | + CUDA Runtime native Libraries + doc_url: https://docs.nvidia.com/cuda/index.html + +extra: + recipe-maintainers: + - adibbley From 54e9ad1cc8a889383fcdaffd26085638fa0d0ded Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 13 Jan 2023 15:53:44 -0500 Subject: [PATCH 02/40] Update license --- recipes/cuda-cudart/meta.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 835dead2b06e2..5d1918ed00635 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -66,7 +66,10 @@ outputs: about: home: https://developer.nvidia.com/cuda-toolkit + license_file: LICENSE + license: LicenseRef-NVIDIA-End-User-License-Agreement license_url: https://docs.nvidia.com/cuda/eula/index.html + summary: CUDA Runtime native Libraries description: | CUDA Runtime native Libraries doc_url: https://docs.nvidia.com/cuda/index.html From 77d5387019903d0dcb1158026f572fd5458693f7 Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 13 Jan 2023 15:55:53 -0500 Subject: [PATCH 03/40] Set targets directory linux only --- recipes/cuda-cudart/meta.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 5d1918ed00635..2969d41291ac7 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -40,7 +40,7 @@ outputs: - name: cuda-cudart files: - lib/*.so.* - - targets/*/lib/*.so.* + - targets/*/lib/*.so.* # [linux] - name: cuda-cudart-dev requirements: @@ -48,7 +48,7 @@ outputs: - cuda-cudart >={{ version }} files: - lib/*.so - - targets/*/lib/*.so + - targets/*/lib/*.so # [linux] - include - name: cuda-cudart-static @@ -57,12 +57,12 @@ outputs: - cuda-cudart-dev >={{ version }} files: - lib/*.a - - targets/*/lib/*.a + - targets/*/lib/*.a # [linux] - name: cuda-driver-dev files: - lib/stubs/libcuda.so - - targets/*/lib/stubs/libcuda.so + - targets/*/lib/stubs/libcuda.so # [linux] about: home: https://developer.nvidia.com/cuda-toolkit From cb4ddf1225bed7436923e1052c059c0ff4b7a390 Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 13 Jan 2023 16:22:51 -0500 Subject: [PATCH 04/40] Fixup windows libs --- recipes/cuda-cudart/meta.yaml | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 2969d41291ac7..fd1c364949d97 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -39,31 +39,41 @@ requirements: outputs: - name: cuda-cudart files: - - lib/*.so.* + - lib/*.so.* # [linux] - targets/*/lib/*.so.* # [linux] + - lib/x64/cuda.lib # [win] + - lib/x64/cudart.lib # [win] - name: cuda-cudart-dev requirements: run: - cuda-cudart >={{ version }} files: - - lib/*.so - - targets/*/lib/*.so # [linux] + - lib/*.so # [linux] + - targets/*/lib/*.so # [linux] - include + - lib/x64/cudadevrt.lib # [win] + - bin # [win] - name: cuda-cudart-static requirements: run: - cuda-cudart-dev >={{ version }} files: - - lib/*.a - - targets/*/lib/*.a # [linux] + - lib/*.a # [linux] + - targets/*/lib/*.a # [linux] + - lib/x64/cudart_static.lib # [win] - - name: cuda-driver-dev - files: - - lib/stubs/libcuda.so + - name: cuda-driver-dev # [linux] + files: # [linux] + - lib/stubs/libcuda.so # [linux] - targets/*/lib/stubs/libcuda.so # [linux] +test: + commands: + - test -f $PREFIX/lib/libcudart.so.{{ version }} # [unix] + - if not exist %LIBRARY_LIB%\\libcudart.so.{{ version }} exit 1 # [win] + about: home: https://developer.nvidia.com/cuda-toolkit license_file: LICENSE From aeabc3aae4a80cfc8880e8e5081c947489fc6bf5 Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 13 Jan 2023 16:27:20 -0500 Subject: [PATCH 05/40] Test block expected above outputs --- recipes/cuda-cudart/meta.yaml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index fd1c364949d97..beea7e99711d3 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -36,6 +36,11 @@ requirements: - sysroot_{{ target_platform }} 2.17 # [linux] - __glibc >=2.17 # [linux] +test: + commands: + - test -f $PREFIX/lib/libcudart.so.{{ version }} # [unix] + - if not exist %LIBRARY_LIB%\\libcudart.so.{{ version }} exit 1 # [win] + outputs: - name: cuda-cudart files: @@ -69,11 +74,6 @@ outputs: - lib/stubs/libcuda.so # [linux] - targets/*/lib/stubs/libcuda.so # [linux] -test: - commands: - - test -f $PREFIX/lib/libcudart.so.{{ version }} # [unix] - - if not exist %LIBRARY_LIB%\\libcudart.so.{{ version }} exit 1 # [win] - about: home: https://developer.nvidia.com/cuda-toolkit license_file: LICENSE From 753fdda1236741c39f4c2a65b1da4358fa3764ba Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 13 Jan 2023 16:50:55 -0500 Subject: [PATCH 06/40] Fixing copy paste in test --- recipes/cuda-cudart/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index beea7e99711d3..c6dd949c82c7a 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -39,7 +39,7 @@ requirements: test: commands: - test -f $PREFIX/lib/libcudart.so.{{ version }} # [unix] - - if not exist %LIBRARY_LIB%\\libcudart.so.{{ version }} exit 1 # [win] + - if not exist %LIBRARY_LIB%\\cudart.lib exit 1 # [win] outputs: - name: cuda-cudart From 2a953152aeea768b88fc54ede9ac0b4c97e56759 Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Fri, 13 Jan 2023 19:10:06 -0500 Subject: [PATCH 07/40] Update recipes/cuda-cudart/meta.yaml Co-authored-by: jakirkham --- recipes/cuda-cudart/meta.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index c6dd949c82c7a..2995dfaf45d7f 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -69,7 +69,9 @@ outputs: - targets/*/lib/*.a # [linux] - lib/x64/cudart_static.lib # [win] - - name: cuda-driver-dev # [linux] + - name: cuda-driver-dev + build: + skip: True # [not linux] files: # [linux] - lib/stubs/libcuda.so # [linux] - targets/*/lib/stubs/libcuda.so # [linux] From cb069716755a5d939959e5f6daf40b429a80c6f8 Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Fri, 13 Jan 2023 19:10:13 -0500 Subject: [PATCH 08/40] Update recipes/cuda-cudart/meta.yaml Co-authored-by: jakirkham --- recipes/cuda-cudart/meta.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 2995dfaf45d7f..cd7457973e134 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -72,9 +72,9 @@ outputs: - name: cuda-driver-dev build: skip: True # [not linux] - files: # [linux] - - lib/stubs/libcuda.so # [linux] - - targets/*/lib/stubs/libcuda.so # [linux] + files: + - lib/stubs/libcuda.so + - targets/*/lib/stubs/libcuda.so about: home: https://developer.nvidia.com/cuda-toolkit From e47fc749a496243e7b881aa6bb9af6dbc6a9bd9d Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 13 Jan 2023 19:33:55 -0500 Subject: [PATCH 09/40] Update recipes/cuda-cudart/meta.yaml --- recipes/cuda-cudart/meta.yaml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index cd7457973e134..afb70237b9f2f 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -21,8 +21,8 @@ source: build: number: 0 skip: true # [osx] - run_exports: - strong: + run_exports: # [linux] + strong: # [linux] - __glibc >=2.17 # [linux] requirements: @@ -38,8 +38,7 @@ requirements: test: commands: - - test -f $PREFIX/lib/libcudart.so.{{ version }} # [unix] - - if not exist %LIBRARY_LIB%\\cudart.lib exit 1 # [win] + - test -f $PREFIX/lib/libcudart.so.{{ version }} # [linux] outputs: - name: cuda-cudart From 47c0e1222f0847e8ba608ab431782ec7251f555d Mon Sep 17 00:00:00 2001 From: adibbley Date: Mon, 16 Jan 2023 09:41:37 -0500 Subject: [PATCH 10/40] Add targets include directory --- recipes/cuda-cudart/meta.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index afb70237b9f2f..9c07a82baa2cf 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -56,6 +56,7 @@ outputs: - lib/*.so # [linux] - targets/*/lib/*.so # [linux] - include + - targets/*/include/*.h # [linux] - lib/x64/cudadevrt.lib # [win] - bin # [win] From 1a3b33326ebe114d2b8a93178afb1ef2878b44a0 Mon Sep 17 00:00:00 2001 From: adibbley Date: Mon, 16 Jan 2023 10:09:43 -0500 Subject: [PATCH 11/40] Pick up a few more missing headers --- recipes/cuda-cudart/meta.yaml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 9c07a82baa2cf..42d254e047ba9 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -53,12 +53,13 @@ outputs: run: - cuda-cudart >={{ version }} files: - - lib/*.so # [linux] - - targets/*/lib/*.so # [linux] + - lib/*.so # [linux] + - targets/*/lib/*.so # [linux] - include - - targets/*/include/*.h # [linux] - - lib/x64/cudadevrt.lib # [win] - - bin # [win] + - targets/*/include/* # [linux] + - targets/*/include/cooperative_groups/* # [linux] + - lib/x64/cudadevrt.lib # [win] + - bin # [win] - name: cuda-cudart-static requirements: From f8e274b77dd8f9b41b0f941f842a92714b867aee Mon Sep 17 00:00:00 2001 From: adibbley Date: Tue, 17 Jan 2023 13:14:18 -0500 Subject: [PATCH 12/40] Update Windows install paths --- recipes/cuda-cudart/bld.bat | 19 ++++--------------- recipes/cuda-cudart/meta.yaml | 22 ++++++++++++---------- 2 files changed, 16 insertions(+), 25 deletions(-) diff --git a/recipes/cuda-cudart/bld.bat b/recipes/cuda-cudart/bld.bat index 6af6c302f87a4..620271a6236b8 100644 --- a/recipes/cuda-cudart/bld.bat +++ b/recipes/cuda-cudart/bld.bat @@ -1,17 +1,6 @@ if not exist %PREFIX% mkdir %PREFIX% -rem Directories... -for /D %%i in (.\*) do ( - robocopy /E %%i %PREFIX%\%%i -) - -rem Files... -for %%i in (.\*) do ( - if not %%~ni==build_env_setup ( - if not %%~ni==conda_build ( - if not %%~ni==metadata_conda_debug ( - xcopy %%i %PREFIX% - ) - ) - ) -) +move lib\x64\* %LIBRARY_LIB% +move bin\* %LIBRARY_BIN% +move include\cooperative_groups %LIBRARY_INC% +move include\* %LIBRARY_INC% diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 42d254e047ba9..379131f5330d8 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -39,14 +39,15 @@ requirements: test: commands: - test -f $PREFIX/lib/libcudart.so.{{ version }} # [linux] + - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] outputs: - name: cuda-cudart files: - - lib/*.so.* # [linux] - - targets/*/lib/*.so.* # [linux] - - lib/x64/cuda.lib # [win] - - lib/x64/cudart.lib # [win] + - lib/*.so.* # [linux] + - targets/*/lib/*.so.* # [linux] + - Library\lib\cuda.lib # [win] + - Library\lib\cudart.lib # [win] - name: cuda-cudart-dev requirements: @@ -55,20 +56,21 @@ outputs: files: - lib/*.so # [linux] - targets/*/lib/*.so # [linux] - - include + - include # [linux] - targets/*/include/* # [linux] - targets/*/include/cooperative_groups/* # [linux] - - lib/x64/cudadevrt.lib # [win] - - bin # [win] + - Library\include # [win] + - Library\lib\cudadevrt.lib # [win] + - Library\bin # [win] - name: cuda-cudart-static requirements: run: - cuda-cudart-dev >={{ version }} files: - - lib/*.a # [linux] - - targets/*/lib/*.a # [linux] - - lib/x64/cudart_static.lib # [win] + - lib/*.a # [linux] + - targets/*/lib/*.a # [linux] + - Library\lib\cudart_static.lib # [win] - name: cuda-driver-dev build: From c0cd174f45d592efb4c37cf22bb7d62d958bacdb Mon Sep 17 00:00:00 2001 From: adibbley Date: Wed, 18 Jan 2023 18:55:17 -0500 Subject: [PATCH 13/40] Adding pkgconfigs --- recipes/cuda-cudart/build.sh | 1 + recipes/cuda-cudart/meta.yaml | 1 + recipes/cuda-cudart/post-link.sh | 5 +++++ 3 files changed, 7 insertions(+) create mode 100644 recipes/cuda-cudart/post-link.sh diff --git a/recipes/cuda-cudart/build.sh b/recipes/cuda-cudart/build.sh index 88d88e1c61295..2071a86b1b8f3 100644 --- a/recipes/cuda-cudart/build.sh +++ b/recipes/cuda-cudart/build.sh @@ -2,6 +2,7 @@ # Install to conda style directories [[ -d lib64 ]] && mv lib64 lib +[[ -d pkg-config ]] && mv pkg-config ${PREFIX}/lib/pkgconfig [[ ${target_platform} == "linux-64" ]] && targetsDir="targets/x86_64-linux" [[ ${target_platform} == "linux-ppc64le" ]] && targetsDir="targets/ppc64le-linux" diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 379131f5330d8..b4393808f6615 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -59,6 +59,7 @@ outputs: - include # [linux] - targets/*/include/* # [linux] - targets/*/include/cooperative_groups/* # [linux] + - lib/pkgconfig # [linux] - Library\include # [win] - Library\lib\cudadevrt.lib # [win] - Library\bin # [win] diff --git a/recipes/cuda-cudart/post-link.sh b/recipes/cuda-cudart/post-link.sh new file mode 100644 index 0000000000000..bb02076ec98ee --- /dev/null +++ b/recipes/cuda-cudart/post-link.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +[[ -d "$PREFIX/lib/pkgconfig" ]] && sed -E -i "s|cudaroot=.+|cudaroot=$PREFIX|g" $PREFIX/lib/pkgconfig/cuda*.pc + +exit 0 From 3ab1ad9c84178303d81558668276ee752eb0ab6c Mon Sep 17 00:00:00 2001 From: adibbley Date: Wed, 18 Jan 2023 19:11:44 -0500 Subject: [PATCH 14/40] Moving post-link.sh into build.sh --- recipes/cuda-cudart/build.sh | 1 + recipes/cuda-cudart/post-link.sh | 5 ----- 2 files changed, 1 insertion(+), 5 deletions(-) delete mode 100644 recipes/cuda-cudart/post-link.sh diff --git a/recipes/cuda-cudart/build.sh b/recipes/cuda-cudart/build.sh index 2071a86b1b8f3..a8d611011fbd8 100644 --- a/recipes/cuda-cudart/build.sh +++ b/recipes/cuda-cudart/build.sh @@ -3,6 +3,7 @@ # Install to conda style directories [[ -d lib64 ]] && mv lib64 lib [[ -d pkg-config ]] && mv pkg-config ${PREFIX}/lib/pkgconfig +[[ -d "$PREFIX/lib/pkgconfig" ]] && sed -E -i "s|cudaroot=.+|cudaroot=$PREFIX|g" $PREFIX/lib/pkgconfig/cuda*.pc [[ ${target_platform} == "linux-64" ]] && targetsDir="targets/x86_64-linux" [[ ${target_platform} == "linux-ppc64le" ]] && targetsDir="targets/ppc64le-linux" diff --git a/recipes/cuda-cudart/post-link.sh b/recipes/cuda-cudart/post-link.sh deleted file mode 100644 index bb02076ec98ee..0000000000000 --- a/recipes/cuda-cudart/post-link.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -[[ -d "$PREFIX/lib/pkgconfig" ]] && sed -E -i "s|cudaroot=.+|cudaroot=$PREFIX|g" $PREFIX/lib/pkgconfig/cuda*.pc - -exit 0 From dc4a28d35b66c84c612198deee35a37d9ecda5f8 Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 20 Jan 2023 14:12:02 -0500 Subject: [PATCH 15/40] Fixing run/dev split on windows and adding output tests --- recipes/cuda-cudart/meta.yaml | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index b4393808f6615..44bc556374564 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -36,23 +36,25 @@ requirements: - sysroot_{{ target_platform }} 2.17 # [linux] - __glibc >=2.17 # [linux] -test: - commands: - - test -f $PREFIX/lib/libcudart.so.{{ version }} # [linux] - - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] - outputs: - name: cuda-cudart + test: + commands: + - test -f $PREFIX/lib/libcudart.so.{{ version }} # [linux] + - if not exist %LIBRARY_BIN%\cudart64_*.dll exit 1 # [win] files: - lib/*.so.* # [linux] - targets/*/lib/*.so.* # [linux] - - Library\lib\cuda.lib # [win] - - Library\lib\cudart.lib # [win] + - Library\bin # [win] - name: cuda-cudart-dev requirements: run: - cuda-cudart >={{ version }} + test: + commands: + - test -d $PREFIX/lib/pkgconfig # [linux] + - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] files: - lib/*.so # [linux] - targets/*/lib/*.so # [linux] @@ -62,7 +64,8 @@ outputs: - lib/pkgconfig # [linux] - Library\include # [win] - Library\lib\cudadevrt.lib # [win] - - Library\bin # [win] + - Library\lib\cuda.lib # [win] + - Library\lib\cudart.lib # [win] - name: cuda-cudart-static requirements: From dada5b9a4c1b319c15bfefcbfd9923e051d9147a Mon Sep 17 00:00:00 2001 From: adibbley Date: Fri, 20 Jan 2023 14:21:32 -0500 Subject: [PATCH 16/40] Add cuda-cudart-static and cuda-driver-dev tests --- recipes/cuda-cudart/meta.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 44bc556374564..109cb344fab04 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -71,6 +71,10 @@ outputs: requirements: run: - cuda-cudart-dev >={{ version }} + test: + commands: + - test -f $PREFIX/lib/libcudart_static.a # [linux] + - if not exist %LIBRARY_LIB%\cudart_static.lib exit 1 # [win] files: - lib/*.a # [linux] - targets/*/lib/*.a # [linux] @@ -79,6 +83,9 @@ outputs: - name: cuda-driver-dev build: skip: True # [not linux] + test: + commands: + - test -f $PREFIX/lib/stubs/libcuda.so files: - lib/stubs/libcuda.so - targets/*/lib/stubs/libcuda.so From ec2a827e767607b7006556cb4f358fbbb8913672 Mon Sep 17 00:00:00 2001 From: adibbley Date: Mon, 23 Jan 2023 14:06:02 -0500 Subject: [PATCH 17/40] Add run_exports for cuda-cudart-dev --- recipes/cuda-cudart/meta.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 109cb344fab04..29fae0a7405d6 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -48,6 +48,9 @@ outputs: - Library\bin # [win] - name: cuda-cudart-dev + run_exports: + strong: + - {{ pin_subpackage("cuda-cudart", max_pin='x') }} requirements: run: - cuda-cudart >={{ version }} From 3d090084320c911a2da7fbae77bc10416579c9b6 Mon Sep 17 00:00:00 2001 From: adibbley Date: Mon, 23 Jan 2023 18:59:18 -0500 Subject: [PATCH 18/40] Flip dev to require static package --- recipes/cuda-cudart/meta.yaml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 29fae0a7405d6..806193b0511fa 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -54,6 +54,7 @@ outputs: requirements: run: - cuda-cudart >={{ version }} + - cuda-cudart-static >={{ version }} test: commands: - test -d $PREFIX/lib/pkgconfig # [linux] @@ -71,9 +72,6 @@ outputs: - Library\lib\cudart.lib # [win] - name: cuda-cudart-static - requirements: - run: - - cuda-cudart-dev >={{ version }} test: commands: - test -f $PREFIX/lib/libcudart_static.a # [linux] From 7fdd23eaf62c736a6f5954e5c13793da33344620 Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Tue, 24 Jan 2023 16:25:08 -0500 Subject: [PATCH 19/40] Update recipes/cuda-cudart/meta.yaml Co-authored-by: jakirkham --- recipes/cuda-cudart/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 806193b0511fa..fdf2508bad4b7 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -49,7 +49,7 @@ outputs: - name: cuda-cudart-dev run_exports: - strong: + weak: - {{ pin_subpackage("cuda-cudart", max_pin='x') }} requirements: run: From d966b9a25fead5f006f31bcb7846a5035e1d485a Mon Sep 17 00:00:00 2001 From: adibbley Date: Thu, 2 Feb 2023 10:02:28 -0500 Subject: [PATCH 20/40] Add cross package proposal --- recipes/cuda-cudart/meta.yaml | 48 ++++++++++++++++++++++++++++++----- 1 file changed, 41 insertions(+), 7 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index fdf2508bad4b7..a92d4a8c24714 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -55,40 +55,74 @@ outputs: run: - cuda-cudart >={{ version }} - cuda-cudart-static >={{ version }} + - cuda-cudart-dev_{{ target_platform }} =={{ version }} # [linux] test: commands: - test -d $PREFIX/lib/pkgconfig # [linux] - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] files: - lib/*.so # [linux] - - targets/*/lib/*.so # [linux] - include # [linux] - - targets/*/include/* # [linux] - - targets/*/include/cooperative_groups/* # [linux] - lib/pkgconfig # [linux] - Library\include # [win] - Library\lib\cudadevrt.lib # [win] - Library\lib\cuda.lib # [win] - Library\lib\cudart.lib # [win] + - name: cuda-cudart-dev_{{ target_platform }} + build: + skip: True # [not linux] + requirements: + run: + - cuda-cudart-dev_{{ target_platform }} >={{ version }} + test: + commands: + - test -L $PREFIX/targets/*/lib/libcudart.so + files: + - targets/*/lib/*.so + - targets/*/include/* + - targets/*/include/cooperative_groups/* + - name: cuda-cudart-static + requirements: + run: + - cuda-cudart-static_{{ target_platform }} =={{ version }} # [linux] test: commands: - - test -f $PREFIX/lib/libcudart_static.a # [linux] - - if not exist %LIBRARY_LIB%\cudart_static.lib exit 1 # [win] + - test -L $PREFIX/lib/libcudart_static.a # [linux] + - if not exist %LIBRARY_LIB%\cudart_static.lib exit 1 # [win] files: - lib/*.a # [linux] - - targets/*/lib/*.a # [linux] - Library\lib\cudart_static.lib # [win] + - name: cuda-cudart-static_{{ target_platform }} + build: + skip: True # [not linux] + requirements: + run: + - cuda-driver-dev_{{ target_platform }} =={{ version }} # [linux] + test: + commands: + - test -f $PREFIX/targets/*/lib/libcudart_static.a # [linux] + files: + - targets/*/lib/*.a # [linux] + - name: cuda-driver-dev build: skip: True # [not linux] test: commands: - - test -f $PREFIX/lib/stubs/libcuda.so + - test -L $PREFIX/lib/stubs files: - lib/stubs/libcuda.so + + - name: cuda-driver-dev_{{ target_platform }} + build: + skip: True # [not linux] + test: + commands: + - test -f $PREFIX/targets/*/lib/stubs/libcuda.so + files: - targets/*/lib/stubs/libcuda.so about: From 855014cd0fd2726fea222c977029d623491ab402 Mon Sep 17 00:00:00 2001 From: adibbley Date: Thu, 2 Feb 2023 13:58:59 -0500 Subject: [PATCH 21/40] Fix dependencies and set cross packages to noarch --- recipes/cuda-cudart/meta.yaml | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index a92d4a8c24714..b409c6639e4e7 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -70,11 +70,12 @@ outputs: - Library\lib\cudart.lib # [win] - name: cuda-cudart-dev_{{ target_platform }} - build: - skip: True # [not linux] requirements: run: - - cuda-cudart-dev_{{ target_platform }} >={{ version }} + - cuda-cudart-static_{{ target_platform }} >={{ version }} + build: + skip: True # [not linux] + noarch: generic test: commands: - test -L $PREFIX/targets/*/lib/libcudart.so @@ -98,9 +99,7 @@ outputs: - name: cuda-cudart-static_{{ target_platform }} build: skip: True # [not linux] - requirements: - run: - - cuda-driver-dev_{{ target_platform }} =={{ version }} # [linux] + noarch: generic test: commands: - test -f $PREFIX/targets/*/lib/libcudart_static.a # [linux] @@ -108,6 +107,9 @@ outputs: - targets/*/lib/*.a # [linux] - name: cuda-driver-dev + requirements: + run: + - cuda-driver-dev_{{ target_platform }} =={{ version }} # [linux] build: skip: True # [not linux] test: @@ -119,6 +121,7 @@ outputs: - name: cuda-driver-dev_{{ target_platform }} build: skip: True # [not linux] + noarch: generic test: commands: - test -f $PREFIX/targets/*/lib/stubs/libcuda.so From c098e5d483da97075dbc6053d8a837c1da27912c Mon Sep 17 00:00:00 2001 From: adibbley Date: Thu, 2 Feb 2023 14:11:20 -0500 Subject: [PATCH 22/40] Flip build/requirements in outputs --- recipes/cuda-cudart/meta.yaml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index b409c6639e4e7..53462d5860174 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -70,12 +70,12 @@ outputs: - Library\lib\cudart.lib # [win] - name: cuda-cudart-dev_{{ target_platform }} - requirements: - run: - - cuda-cudart-static_{{ target_platform }} >={{ version }} build: skip: True # [not linux] noarch: generic + requirements: + run: + - cuda-cudart-static_{{ target_platform }} >={{ version }} test: commands: - test -L $PREFIX/targets/*/lib/libcudart.so @@ -107,11 +107,11 @@ outputs: - targets/*/lib/*.a # [linux] - name: cuda-driver-dev + build: + skip: True # [not linux] requirements: run: - cuda-driver-dev_{{ target_platform }} =={{ version }} # [linux] - build: - skip: True # [not linux] test: commands: - test -L $PREFIX/lib/stubs From 039461a80cedd9649c23b272340365ad261b254d Mon Sep 17 00:00:00 2001 From: adibbley Date: Mon, 6 Feb 2023 18:34:49 -0500 Subject: [PATCH 23/40] Enable target package for windows --- recipes/cuda-cudart/meta.yaml | 53 +++++++++++++++++------------------ 1 file changed, 26 insertions(+), 27 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 53462d5860174..18babc9b6e102 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -48,63 +48,62 @@ outputs: - Library\bin # [win] - name: cuda-cudart-dev - run_exports: - weak: - - {{ pin_subpackage("cuda-cudart", max_pin='x') }} + #run_exports: + # weak: + # - {{ pin_subpackage("cuda-cudart", max_pin='x') }} requirements: run: - cuda-cudart >={{ version }} - cuda-cudart-static >={{ version }} - - cuda-cudart-dev_{{ target_platform }} =={{ version }} # [linux] + - cuda-cudart-dev_{{ target_platform }} =={{ version }} test: commands: - - test -d $PREFIX/lib/pkgconfig # [linux] - - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] - files: - - lib/*.so # [linux] - - include # [linux] - - lib/pkgconfig # [linux] - - Library\include # [win] - - Library\lib\cudadevrt.lib # [win] - - Library\lib\cuda.lib # [win] - - Library\lib\cudart.lib # [win] + - test -d $PREFIX/lib/pkgconfig # [linux] + files: # [linux] + - lib/*.so # [linux] + - include # [linux] + - lib/pkgconfig # [linux] - name: cuda-cudart-dev_{{ target_platform }} build: - skip: True # [not linux] noarch: generic requirements: run: - cuda-cudart-static_{{ target_platform }} >={{ version }} test: commands: - - test -L $PREFIX/targets/*/lib/libcudart.so + - test -L $PREFIX/targets/*/lib/libcudart.so # [linux] + - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] files: - - targets/*/lib/*.so - - targets/*/include/* - - targets/*/include/cooperative_groups/* + - targets/*/lib/*.so # [linux] + - targets/*/include/* # [linux] + - targets/*/include/cooperative_groups/* # [linux] + - Library\include # [win] + - Library\lib\cudadevrt.lib # [win] + - Library\lib\cuda.lib # [win] + - Library\lib\cudart.lib # [win] - name: cuda-cudart-static requirements: run: - - cuda-cudart-static_{{ target_platform }} =={{ version }} # [linux] + - cuda-cudart-static_{{ target_platform }} =={{ version }} test: commands: - - test -L $PREFIX/lib/libcudart_static.a # [linux] - - if not exist %LIBRARY_LIB%\cudart_static.lib exit 1 # [win] - files: - - lib/*.a # [linux] - - Library\lib\cudart_static.lib # [win] + - test -L $PREFIX/lib/libcudart_static.a # [linux] + files: # [linux] + - lib/*.a # [linux] - name: cuda-cudart-static_{{ target_platform }} build: - skip: True # [not linux] noarch: generic test: commands: - - test -f $PREFIX/targets/*/lib/libcudart_static.a # [linux] + - test -f $PREFIX/targets/*/lib/libcudart_static.a # [linux] + - if not exist %LIBRARY_LIB%\cudart_static.lib exit 1 # [win] files: - targets/*/lib/*.a # [linux] + - Library\lib\cudart_static.lib # [win] + - name: cuda-driver-dev build: From a3c7bae7f72d1730f4269491b98e179b56142126 Mon Sep 17 00:00:00 2001 From: adibbley Date: Mon, 6 Feb 2023 18:48:11 -0500 Subject: [PATCH 24/40] Adding run_exports to dev packages --- recipes/cuda-cudart/meta.yaml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 18babc9b6e102..a9cc60985d357 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -48,9 +48,9 @@ outputs: - Library\bin # [win] - name: cuda-cudart-dev - #run_exports: - # weak: - # - {{ pin_subpackage("cuda-cudart", max_pin='x') }} + run_exports: + weak: + - {{ pin_subpackage("cuda-cudart", max_pin='x') }} requirements: run: - cuda-cudart >={{ version }} @@ -65,6 +65,9 @@ outputs: - lib/pkgconfig # [linux] - name: cuda-cudart-dev_{{ target_platform }} + run_exports: + weak: + - {{ pin_subpackage("cuda-cudart", max_pin='x') }} build: noarch: generic requirements: From fae8026b9c49e4f71c81f3901107245e9470d142 Mon Sep 17 00:00:00 2001 From: adibbley Date: Tue, 7 Feb 2023 15:27:48 -0500 Subject: [PATCH 25/40] More specific wildcards for runtime package --- recipes/cuda-cudart/meta.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index a9cc60985d357..9f4c8ba4b7934 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -43,9 +43,9 @@ outputs: - test -f $PREFIX/lib/libcudart.so.{{ version }} # [linux] - if not exist %LIBRARY_BIN%\cudart64_*.dll exit 1 # [win] files: - - lib/*.so.* # [linux] + - lib/libcu*.so.* # [linux] - targets/*/lib/*.so.* # [linux] - - Library\bin # [win] + - Library\bin\cudart*.dll # [win] - name: cuda-cudart-dev run_exports: From 7fd615f45cdd879234cb53ceda3bac82b504ccba Mon Sep 17 00:00:00 2001 From: adibbley Date: Tue, 14 Feb 2023 11:54:08 -0500 Subject: [PATCH 26/40] Adding cuda-cccl dependency --- recipes/cuda-cudart/meta.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 9f4c8ba4b7934..4d9eda60d95bf 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -56,6 +56,7 @@ outputs: - cuda-cudart >={{ version }} - cuda-cudart-static >={{ version }} - cuda-cudart-dev_{{ target_platform }} =={{ version }} + - cuda-cccl >=12.0,<13 test: commands: - test -d $PREFIX/lib/pkgconfig # [linux] From cbce9116aecc944bfc4fcbac214bc211f652a5e3 Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Wed, 15 Mar 2023 09:58:39 -0400 Subject: [PATCH 27/40] Update recipes/cuda-cudart/meta.yaml Co-authored-by: Bradley Dice --- recipes/cuda-cudart/meta.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 4d9eda60d95bf..89cabad69cb76 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -57,6 +57,7 @@ outputs: - cuda-cudart-static >={{ version }} - cuda-cudart-dev_{{ target_platform }} =={{ version }} - cuda-cccl >=12.0,<13 + - cuda-version =12.0 test: commands: - test -d $PREFIX/lib/pkgconfig # [linux] From d0847bb893f3585cc8f568b49c128b5295b6516f Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Fri, 17 Mar 2023 09:28:37 -0400 Subject: [PATCH 28/40] Apply suggestions from code review Co-authored-by: Bradley Dice --- recipes/cuda-cudart/meta.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 89cabad69cb76..2e04f3b5463e1 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -75,6 +75,7 @@ outputs: requirements: run: - cuda-cudart-static_{{ target_platform }} >={{ version }} + - cuda-version =12.0 test: commands: - test -L $PREFIX/targets/*/lib/libcudart.so # [linux] @@ -92,6 +93,7 @@ outputs: requirements: run: - cuda-cudart-static_{{ target_platform }} =={{ version }} + - cuda-version =12.0 test: commands: - test -L $PREFIX/lib/libcudart_static.a # [linux] @@ -99,6 +101,9 @@ outputs: - lib/*.a # [linux] - name: cuda-cudart-static_{{ target_platform }} + requirements: + run: + - cuda-version =12.0 build: noarch: generic test: @@ -116,6 +121,7 @@ outputs: requirements: run: - cuda-driver-dev_{{ target_platform }} =={{ version }} # [linux] + - cuda-version =12.0 test: commands: - test -L $PREFIX/lib/stubs @@ -123,6 +129,9 @@ outputs: - lib/stubs/libcuda.so - name: cuda-driver-dev_{{ target_platform }} + requirements: + run: + - cuda-version =12.0 build: skip: True # [not linux] noarch: generic From 9278294a2e6cb833f48058ef8f363501baf12007 Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Wed, 22 Mar 2023 09:04:05 -0400 Subject: [PATCH 29/40] Apply suggestions from code review Co-authored-by: Bradley Dice --- recipes/cuda-cudart/meta.yaml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 2e04f3b5463e1..3d22dfb1ded20 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -1,5 +1,6 @@ {% set name = "cuda-cudart" %} {% set version = "12.0.107" %} +{% set cuda_version = "12.0" %} {% set platform = "linux-x86_64" %} # [linux64] {% set platform = "linux-ppc64le" %} # [ppc64le] {% set platform = "linux-sbsa" %} # [aarch64] @@ -57,7 +58,7 @@ outputs: - cuda-cudart-static >={{ version }} - cuda-cudart-dev_{{ target_platform }} =={{ version }} - cuda-cccl >=12.0,<13 - - cuda-version =12.0 + - cuda-version {{ cuda_version }} test: commands: - test -d $PREFIX/lib/pkgconfig # [linux] @@ -75,7 +76,7 @@ outputs: requirements: run: - cuda-cudart-static_{{ target_platform }} >={{ version }} - - cuda-version =12.0 + - cuda-version {{ cuda_version }} test: commands: - test -L $PREFIX/targets/*/lib/libcudart.so # [linux] @@ -93,7 +94,7 @@ outputs: requirements: run: - cuda-cudart-static_{{ target_platform }} =={{ version }} - - cuda-version =12.0 + - cuda-version {{ cuda_version }} test: commands: - test -L $PREFIX/lib/libcudart_static.a # [linux] @@ -103,7 +104,7 @@ outputs: - name: cuda-cudart-static_{{ target_platform }} requirements: run: - - cuda-version =12.0 + - cuda-version {{ cuda_version }} build: noarch: generic test: @@ -121,7 +122,7 @@ outputs: requirements: run: - cuda-driver-dev_{{ target_platform }} =={{ version }} # [linux] - - cuda-version =12.0 + - cuda-version {{ cuda_version }} test: commands: - test -L $PREFIX/lib/stubs @@ -131,7 +132,7 @@ outputs: - name: cuda-driver-dev_{{ target_platform }} requirements: run: - - cuda-version =12.0 + - cuda-version {{ cuda_version }} build: skip: True # [not linux] noarch: generic From f4c6f2db2760142a2c1537ed2f6a7171e4218bd7 Mon Sep 17 00:00:00 2001 From: Bradley Dice Date: Fri, 31 Mar 2023 16:10:06 -0500 Subject: [PATCH 30/40] Update recipe. --- recipes/cuda-cudart/build.sh | 33 ++- recipes/cuda-cudart/conda_build_config.yaml | 2 + recipes/cuda-cudart/meta.yaml | 255 ++++++++++++++------ 3 files changed, 203 insertions(+), 87 deletions(-) create mode 100644 recipes/cuda-cudart/conda_build_config.yaml diff --git a/recipes/cuda-cudart/build.sh b/recipes/cuda-cudart/build.sh index a8d611011fbd8..abfedbcdff256 100644 --- a/recipes/cuda-cudart/build.sh +++ b/recipes/cuda-cudart/build.sh @@ -2,6 +2,7 @@ # Install to conda style directories [[ -d lib64 ]] && mv lib64 lib +mkdir -p ${PREFIX}/lib [[ -d pkg-config ]] && mv pkg-config ${PREFIX}/lib/pkgconfig [[ -d "$PREFIX/lib/pkgconfig" ]] && sed -E -i "s|cudaroot=.+|cudaroot=$PREFIX|g" $PREFIX/lib/pkgconfig/cuda*.pc @@ -10,17 +11,23 @@ [[ ${target_platform} == "linux-aarch64" ]] && targetsDir="targets/sbsa-linux" for i in `ls`; do - [[ $i == "build_env_setup.sh" ]] && continue - [[ $i == "conda_build.sh" ]] && continue - [[ $i == "metadata_conda_debug.yaml" ]] && continue - if [[ $i == "lib" ]] || [[ $i == "include" ]]; then - mkdir -p ${PREFIX}/${targetsDir} - mkdir -p ${PREFIX}/$i - cp -rv $i ${PREFIX}/${targetsDir} - for j in `ls $i`; do - ln -s ../${targetsDir}/$i/$j ${PREFIX}/$i/$j - done - else - cp -rv $i ${PREFIX} - fi + [[ $i == "build_env_setup.sh" ]] && continue + [[ $i == "conda_build.sh" ]] && continue + [[ $i == "metadata_conda_debug.yaml" ]] && continue + if [[ $i == "lib" ]] || [[ $i == "include" ]]; then + # Headers and libraries are installed to targetsDir + mkdir -p ${PREFIX}/${targetsDir} + mkdir -p ${PREFIX}/$i + cp -rv $i ${PREFIX}/${targetsDir} + if [[ $i == "lib" ]]; then + for j in "$i"/*.{a,so}*; do + # Shared and static libraries are symlinked in $PREFIX/lib + ln -s ../${targetsDir}/$j ${PREFIX}/$j + done + fi + else + # Put all other files in targetsDir + mkdir -p ${PREFIX}/${targetsDir}/${PKG_NAME} + cp -rv $i ${PREFIX}/${targetsDir}/${PKG_NAME}/$i + fi done diff --git a/recipes/cuda-cudart/conda_build_config.yaml b/recipes/cuda-cudart/conda_build_config.yaml new file mode 100644 index 0000000000000..52229a8424e52 --- /dev/null +++ b/recipes/cuda-cudart/conda_build_config.yaml @@ -0,0 +1,2 @@ +arm_variant_type: # [aarch64] + - sbsa # [aarch64] diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 3d22dfb1ded20..51c220f1abab2 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -5,6 +5,10 @@ {% set platform = "linux-ppc64le" %} # [ppc64le] {% set platform = "linux-sbsa" %} # [aarch64] {% set platform = "windows-x86_64" %} # [win] +{% set target_name = "x86_64-linux" %} # [linux64] +{% set target_name = "ppc64le-linux" %} # [ppc64le] +{% set target_name = "sbsa-linux" %} # [aarch64] +{% set target_name = "x64" %} # [win] {% set extension = "tar.xz" %} # [not win] {% set extension = "zip" %} # [win] @@ -22,125 +26,228 @@ source: build: number: 0 skip: true # [osx] - run_exports: # [linux] - strong: # [linux] - - __glibc >=2.17 # [linux] - -requirements: - build: - - {{ compiler("c") }} - - {{ compiler("cxx") }} - host: - - sysroot_{{ target_platform }} 2.17 # [linux] - - __glibc >=2.17 # [linux] - run: - - sysroot_{{ target_platform }} 2.17 # [linux] - - __glibc >=2.17 # [linux] outputs: - name: cuda-cudart + files: + - lib/libcu*.so.* # [linux] + - targets/{{ target_name }}/lib/libcu*.so.* # [linux] + - Library\bin\cudart*.dll # [win] + requirements: + build: + - {{ compiler("c") }} + - {{ compiler("cxx") }} + - arm-variant * {{ arm_variant_type }} # [aarch64] + - sysroot_{{ target_platform }} 2.17 # [linux] + host: + - cuda-version {{ cuda_version }} + run: + - {{ pin_compatible("cuda-version", max_pin="x.x") }} + run_constrained: + - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: - - test -f $PREFIX/lib/libcudart.so.{{ version }} # [linux] - - if not exist %LIBRARY_BIN%\cudart64_*.dll exit 1 # [win] - files: - - lib/libcu*.so.* # [linux] - - targets/*/lib/*.so.* # [linux] - - Library\bin\cudart*.dll # [win] + - test -L $PREFIX/lib/libcudart.so.{{ version }} # [linux] + - test -L $PREFIX/lib/libcudart.so.{{ version.split(".")[0] }} # [linux] + - test -L $PREFIX/targets/{{ target_name }}/lib/libcudart.so.{{ version }} # [linux] + - test -f $PREFIX/targets/{{ target_name }}/lib/libcudart.so.{{ version.split(".")[0] }} # [linux] + - if not exist %LIBRARY_BIN%\cudart64_{{ version.split(".")[0] }}.dll exit 1 # [win] + about: + home: https://developer.nvidia.com/cuda-toolkit + license_file: LICENSE + license: LicenseRef-NVIDIA-End-User-License-Agreement + license_url: https://docs.nvidia.com/cuda/eula/index.html + summary: CUDA Runtime native Libraries + description: | + CUDA Runtime native Libraries + doc_url: https://docs.nvidia.com/cuda/index.html - name: cuda-cudart-dev - run_exports: - weak: - - {{ pin_subpackage("cuda-cudart", max_pin='x') }} + build: + run_exports: + - {{ pin_subpackage("cuda-cudart", max_pin="x") }} + files: + - lib/libcu*.so # [linux] + - lib/pkgconfig # [linux] requirements: - run: - - cuda-cudart >={{ version }} - - cuda-cudart-static >={{ version }} - - cuda-cudart-dev_{{ target_platform }} =={{ version }} - - cuda-cccl >=12.0,<13 + build: + - {{ compiler("c") }} + - {{ compiler("cxx") }} + - arm-variant * {{ arm_variant_type }} # [aarch64] + - sysroot_{{ target_platform }} 2.17 # [linux] + host: - cuda-version {{ cuda_version }} + run: + - {{ pin_compatible("cuda-version", max_pin="x.x") }} + - {{ pin_subpackage("cuda-cudart", exact=True) }} + - {{ pin_subpackage("cuda-cudart-dev_" + target_platform, exact=True) }} + # TODO: Enable cuda-cccl when it is available. + #- cuda-cccl + run_constrained: + - {{ pin_subpackage("cuda-cudart-static", exact=True) }} # [linux] + - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: - - test -d $PREFIX/lib/pkgconfig # [linux] - files: # [linux] - - lib/*.so # [linux] - - include # [linux] - - lib/pkgconfig # [linux] + - test -L $PREFIX/lib/libcudart.so # [linux] + - test -f $PREFIX/lib/pkgconfig/cuda-*.pc # [linux] + - test -f $PREFIX/lib/pkgconfig/cudart-*.pc # [linux] + about: + home: https://developer.nvidia.com/cuda-toolkit + license_file: LICENSE + license: LicenseRef-NVIDIA-End-User-License-Agreement + license_url: https://docs.nvidia.com/cuda/eula/index.html + summary: CUDA Runtime native Libraries + description: | + CUDA Runtime native Libraries + doc_url: https://docs.nvidia.com/cuda/index.html - name: cuda-cudart-dev_{{ target_platform }} - run_exports: - weak: - - {{ pin_subpackage("cuda-cudart", max_pin='x') }} build: noarch: generic + run_exports: + - {{ pin_subpackage("cuda-cudart", max_pin="x") }} + files: + - targets/{{ target_name }}/include/* # [linux] + - targets/{{ target_name }}/include/cooperative_groups/* # [linux] + - targets/{{ target_name }}/lib/*.so # [linux] + - Library\include # [win] + - Library\lib\cuda.lib # [win] + - Library\lib\cudadevrt.lib # [win] + - Library\lib\cudart.lib # [win] requirements: - run: - - cuda-cudart-static_{{ target_platform }} >={{ version }} + build: + - {{ compiler("c") }} + - {{ compiler("cxx") }} + - arm-variant * {{ arm_variant_type }} # [aarch64] + - sysroot_{{ target_platform }} 2.17 # [linux] + host: - cuda-version {{ cuda_version }} + run: + - {{ pin_compatible("cuda-version", max_pin="x.x") }} + - cuda-cudart-static_{{ target_platform }} + run_constrained: + - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: - - test -L $PREFIX/targets/*/lib/libcudart.so # [linux] - - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] - files: - - targets/*/lib/*.so # [linux] - - targets/*/include/* # [linux] - - targets/*/include/cooperative_groups/* # [linux] - - Library\include # [win] - - Library\lib\cudadevrt.lib # [win] - - Library\lib\cuda.lib # [win] - - Library\lib\cudart.lib # [win] + - test -f $PREFIX/targets/{{ target_name }}/include/cuda.h # [linux] + - test -f $PREFIX/targets/{{ target_name }}/include/cuda_runtime.h # [linux] + - test -f $PREFIX/targets/{{ target_name }}/include/cuda_runtime_api.h # [linux] + - test -L $PREFIX/targets/{{ target_name }}/lib/libcudart.so # [linux] + - if not exist %LIBRARY_INC%\cuda.h exit 1 # [win] + - if not exist %LIBRARY_INC%\cuda_runtime.h exit 1 # [win] + - if not exist %LIBRARY_INC%\cuda_runtime_api.h exit 1 # [win] + - if not exist %LIBRARY_LIB%\cuda.lib exit 1 # [win] + - if not exist %LIBRARY_LIB%\cudadevrt.lib exit 1 # [win] + - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] - name: cuda-cudart-static + files: + - lib/*.a # [linux] requirements: - run: - - cuda-cudart-static_{{ target_platform }} =={{ version }} + build: + - {{ compiler("c") }} + - {{ compiler("cxx") }} + - arm-variant * {{ arm_variant_type }} # [aarch64] + - sysroot_{{ target_platform }} 2.17 # [linux] + host: - cuda-version {{ cuda_version }} + run: + - {{ pin_compatible("cuda-version", max_pin="x.x") }} + - {{ pin_subpackage("cuda-cudart-static_" + target_platform, exact=True) }} + run_constrained: + - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: - test -L $PREFIX/lib/libcudart_static.a # [linux] - files: # [linux] - - lib/*.a # [linux] + - test -L $PREFIX/lib/libcudadevrt.a # [linux] + - test -L $PREFIX/lib/libculibos.a # [linux] - name: cuda-cudart-static_{{ target_platform }} - requirements: - run: - - cuda-version {{ cuda_version }} build: noarch: generic + files: + - targets/{{ target_name }}/lib/*.a # [linux] + - Library\lib\cudart_static.lib # [win] + requirements: + build: + - {{ compiler("c") }} + - {{ compiler("cxx") }} + - arm-variant * {{ arm_variant_type }} # [aarch64] + - sysroot_{{ target_platform }} 2.17 # [linux] + host: + - cuda-version {{ cuda_version }} + run: + - {{ pin_compatible("cuda-version", max_pin="x.x") }} + run_constrained: + - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: - - test -f $PREFIX/targets/*/lib/libcudart_static.a # [linux] - - if not exist %LIBRARY_LIB%\cudart_static.lib exit 1 # [win] - files: - - targets/*/lib/*.a # [linux] - - Library\lib\cudart_static.lib # [win] - + - test -f $PREFIX/targets/{{ target_name }}/lib/libcudart_static.a # [linux] + - test -f $PREFIX/targets/{{ target_name }}/lib/libcudadevrt.a # [linux] + - test -f $PREFIX/targets/{{ target_name }}/lib/libculibos.a # [linux] + - if not exist %LIBRARY_LIB%\cudart_static.lib exit 1 # [win] + about: + home: https://developer.nvidia.com/cuda-toolkit + license_file: LICENSE + license: LicenseRef-NVIDIA-End-User-License-Agreement + license_url: https://docs.nvidia.com/cuda/eula/index.html + summary: CUDA Runtime native Libraries + description: | + CUDA Runtime native Libraries + doc_url: https://docs.nvidia.com/cuda/index.html - name: cuda-driver-dev build: - skip: True # [not linux] + skip: True # [not linux] + files: + - lib/stubs/libcuda.so requirements: - run: - - cuda-driver-dev_{{ target_platform }} =={{ version }} # [linux] + build: + - {{ compiler("c") }} + - {{ compiler("cxx") }} + - arm-variant * {{ arm_variant_type }} # [aarch64] + - sysroot_{{ target_platform }} 2.17 # [linux] + host: - cuda-version {{ cuda_version }} + run: + - {{ pin_compatible("cuda-version", max_pin="x.x") }} + - cuda-driver-dev_{{ target_platform }} + run_constrained: + - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: - - test -L $PREFIX/lib/stubs - files: - - lib/stubs/libcuda.so + - test -L $PREFIX/lib/stubs/libcuda.so - name: cuda-driver-dev_{{ target_platform }} - requirements: - run: - - cuda-version {{ cuda_version }} build: - skip: True # [not linux] + skip: True # [not linux] noarch: generic + files: + - targets/{{ target_name }}/lib/stubs/libcuda.so + requirements: + build: + - {{ compiler("c") }} + - {{ compiler("cxx") }} + - arm-variant * {{ arm_variant_type }} # [aarch64] + - sysroot_{{ target_platform }} 2.17 # [linux] + host: + - cuda-version {{ cuda_version }} + run: + - {{ pin_compatible("cuda-version", max_pin="x.x") }} + run_constrained: + - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: - - test -f $PREFIX/targets/*/lib/stubs/libcuda.so - files: - - targets/*/lib/stubs/libcuda.so + - test -f $PREFIX/targets/{{ target_name }}/lib/stubs/libcuda.so + about: + home: https://developer.nvidia.com/cuda-toolkit + license_file: LICENSE + license: LicenseRef-NVIDIA-End-User-License-Agreement + license_url: https://docs.nvidia.com/cuda/eula/index.html + summary: CUDA Runtime native Libraries + description: | + CUDA Runtime native Libraries + doc_url: https://docs.nvidia.com/cuda/index.html about: home: https://developer.nvidia.com/cuda-toolkit From 7b0d9a70539fdd3303f23ab076284b6f23d59bd7 Mon Sep 17 00:00:00 2001 From: Bradley Dice Date: Mon, 3 Apr 2023 23:40:40 -0500 Subject: [PATCH 31/40] Depend on cuda-cccl_{{ target_platform }} in cuda-cudart-dev_{{ target_platform }}. --- recipes/cuda-cudart/meta.yaml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 51c220f1abab2..4e6edba8fdc0a 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -81,8 +81,6 @@ outputs: - {{ pin_compatible("cuda-version", max_pin="x.x") }} - {{ pin_subpackage("cuda-cudart", exact=True) }} - {{ pin_subpackage("cuda-cudart-dev_" + target_platform, exact=True) }} - # TODO: Enable cuda-cccl when it is available. - #- cuda-cccl run_constrained: - {{ pin_subpackage("cuda-cudart-static", exact=True) }} # [linux] - arm-variant * {{ arm_variant_type }} # [aarch64] @@ -119,6 +117,7 @@ outputs: - {{ compiler("c") }} - {{ compiler("cxx") }} - arm-variant * {{ arm_variant_type }} # [aarch64] + - cuda-cccl_{{ target_platform }} - sysroot_{{ target_platform }} 2.17 # [linux] host: - cuda-version {{ cuda_version }} From f239ddcba680a8bcb2f40b277e30907d6251a7b6 Mon Sep 17 00:00:00 2001 From: adibbley Date: Wed, 5 Apr 2023 08:42:49 -0400 Subject: [PATCH 32/40] Fix stubs/libcuda.so link --- recipes/cuda-cudart/build.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/cuda-cudart/build.sh b/recipes/cuda-cudart/build.sh index abfedbcdff256..5cbda283ee89c 100644 --- a/recipes/cuda-cudart/build.sh +++ b/recipes/cuda-cudart/build.sh @@ -2,7 +2,7 @@ # Install to conda style directories [[ -d lib64 ]] && mv lib64 lib -mkdir -p ${PREFIX}/lib +mkdir -p ${PREFIX}/lib/stubs [[ -d pkg-config ]] && mv pkg-config ${PREFIX}/lib/pkgconfig [[ -d "$PREFIX/lib/pkgconfig" ]] && sed -E -i "s|cudaroot=.+|cudaroot=$PREFIX|g" $PREFIX/lib/pkgconfig/cuda*.pc @@ -20,9 +20,9 @@ for i in `ls`; do mkdir -p ${PREFIX}/$i cp -rv $i ${PREFIX}/${targetsDir} if [[ $i == "lib" ]]; then - for j in "$i"/*.{a,so}*; do + for j in "$i"/{*.a,*.so,stubs/*.so}*; do # Shared and static libraries are symlinked in $PREFIX/lib - ln -s ../${targetsDir}/$j ${PREFIX}/$j + ln -sv ${PREFIX}/${targetsDir}/$j ${PREFIX}/$j done fi else From 5106c8094116d2c4014b7c89acc5fa887c12a80c Mon Sep 17 00:00:00 2001 From: adibbley Date: Wed, 5 Apr 2023 08:43:56 -0400 Subject: [PATCH 33/40] Add about sections to all outputs --- recipes/cuda-cudart/meta.yaml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 4e6edba8fdc0a..b963c993825c8 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -138,6 +138,15 @@ outputs: - if not exist %LIBRARY_LIB%\cuda.lib exit 1 # [win] - if not exist %LIBRARY_LIB%\cudadevrt.lib exit 1 # [win] - if not exist %LIBRARY_LIB%\cudart.lib exit 1 # [win] + about: + home: https://developer.nvidia.com/cuda-toolkit + license_file: LICENSE + license: LicenseRef-NVIDIA-End-User-License-Agreement + license_url: https://docs.nvidia.com/cuda/eula/index.html + summary: CUDA Runtime native Libraries + description: | + CUDA Runtime native Libraries + doc_url: https://docs.nvidia.com/cuda/index.html - name: cuda-cudart-static files: @@ -160,6 +169,15 @@ outputs: - test -L $PREFIX/lib/libcudart_static.a # [linux] - test -L $PREFIX/lib/libcudadevrt.a # [linux] - test -L $PREFIX/lib/libculibos.a # [linux] + about: + home: https://developer.nvidia.com/cuda-toolkit + license_file: LICENSE + license: LicenseRef-NVIDIA-End-User-License-Agreement + license_url: https://docs.nvidia.com/cuda/eula/index.html + summary: CUDA Runtime native Libraries + description: | + CUDA Runtime native Libraries + doc_url: https://docs.nvidia.com/cuda/index.html - name: cuda-cudart-static_{{ target_platform }} build: @@ -216,6 +234,15 @@ outputs: test: commands: - test -L $PREFIX/lib/stubs/libcuda.so + about: + home: https://developer.nvidia.com/cuda-toolkit + license_file: LICENSE + license: LicenseRef-NVIDIA-End-User-License-Agreement + license_url: https://docs.nvidia.com/cuda/eula/index.html + summary: CUDA Runtime native Libraries + description: | + CUDA Runtime native Libraries + doc_url: https://docs.nvidia.com/cuda/index.html - name: cuda-driver-dev_{{ target_platform }} build: From 26d7a5272af01c2e9f84b61665ea58d0f050b53c Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Wed, 5 Apr 2023 13:03:31 -0400 Subject: [PATCH 34/40] Update recipes/cuda-cudart/meta.yaml --- recipes/cuda-cudart/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index b963c993825c8..36e45324cbbb9 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -81,8 +81,8 @@ outputs: - {{ pin_compatible("cuda-version", max_pin="x.x") }} - {{ pin_subpackage("cuda-cudart", exact=True) }} - {{ pin_subpackage("cuda-cudart-dev_" + target_platform, exact=True) }} + - {{ pin_subpackage("cuda-cudart-static", exact=True) }} run_constrained: - - {{ pin_subpackage("cuda-cudart-static", exact=True) }} # [linux] - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: From 97d62e30403a30074564726d501759d34f7393aa Mon Sep 17 00:00:00 2001 From: adibbley Date: Wed, 5 Apr 2023 16:38:50 -0400 Subject: [PATCH 35/40] Move cuda-cccl to run requirement --- recipes/cuda-cudart/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 36e45324cbbb9..02697fe955909 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -117,13 +117,13 @@ outputs: - {{ compiler("c") }} - {{ compiler("cxx") }} - arm-variant * {{ arm_variant_type }} # [aarch64] - - cuda-cccl_{{ target_platform }} - sysroot_{{ target_platform }} 2.17 # [linux] host: - cuda-version {{ cuda_version }} run: - {{ pin_compatible("cuda-version", max_pin="x.x") }} - cuda-cudart-static_{{ target_platform }} + - cuda-cccl_{{ target_platform }} run_constrained: - arm-variant * {{ arm_variant_type }} # [aarch64] test: From 097daa905a5b1010b21e086f2741919200e0b8ba Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Wed, 5 Apr 2023 16:40:34 -0400 Subject: [PATCH 36/40] Apply suggestions from code review Co-authored-by: Keith Kraus --- recipes/cuda-cudart/meta.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 02697fe955909..f6e1eb8f23f4e 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -40,9 +40,9 @@ outputs: - arm-variant * {{ arm_variant_type }} # [aarch64] - sysroot_{{ target_platform }} 2.17 # [linux] host: - - cuda-version {{ cuda_version }} + - cuda-version {{ cuda_version }} run: - - {{ pin_compatible("cuda-version", max_pin="x.x") }} + - {{ pin_compatible("cuda-version", max_pin="x.x") }} run_constrained: - arm-variant * {{ arm_variant_type }} # [aarch64] test: From 52bd85d537de65412461f2fe227909d03221c53e Mon Sep 17 00:00:00 2001 From: adibbley Date: Tue, 11 Apr 2023 11:58:37 -0400 Subject: [PATCH 37/40] Skip files section for Windows metapackages --- recipes/cuda-cudart/meta.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index f6e1eb8f23f4e..75dea317d33c8 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -66,7 +66,7 @@ outputs: build: run_exports: - {{ pin_subpackage("cuda-cudart", max_pin="x") }} - files: + files: # [linux] - lib/libcu*.so # [linux] - lib/pkgconfig # [linux] requirements: @@ -149,7 +149,7 @@ outputs: doc_url: https://docs.nvidia.com/cuda/index.html - name: cuda-cudart-static - files: + files: # [linux] - lib/*.a # [linux] requirements: build: From 20212b95121b52258ee5b2fdf5084ed7fc4db113 Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Tue, 11 Apr 2023 17:21:32 -0400 Subject: [PATCH 38/40] Update recipes/cuda-cudart/meta.yaml Co-authored-by: Bradley Dice --- recipes/cuda-cudart/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 75dea317d33c8..0b853bb100d5c 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -25,7 +25,7 @@ source: build: number: 0 - skip: true # [osx] + skip: true # [osx or win] outputs: - name: cuda-cudart From 622cf4ddc2a88dba9cba9897b00b87c2fc2e0024 Mon Sep 17 00:00:00 2001 From: Bradley Dice Date: Tue, 11 Apr 2023 16:37:45 -0500 Subject: [PATCH 39/40] Fix cuda-cudart tests. --- recipes/cuda-cudart/meta.yaml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index 0b853bb100d5c..e3eab819ce9c1 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -27,6 +27,14 @@ build: number: 0 skip: true # [osx or win] +test: + commands: + - test -L $PREFIX/lib/libcudart.so.{{ version.split(".")[0] }} # [linux] + - test -L $PREFIX/lib/libcudart.so.{{ version }} # [linux] + - test -L $PREFIX/targets/{{ target_name }}/lib/libcudart.so.{{ version.split(".")[0] }} # [linux] + - test -f $PREFIX/targets/{{ target_name }}/lib/libcudart.so.{{ version }} # [linux] + - if not exist %LIBRARY_BIN%\cudart64_{{ version.split(".")[0] }}.dll exit 1 # [win] + outputs: - name: cuda-cudart files: @@ -45,13 +53,7 @@ outputs: - {{ pin_compatible("cuda-version", max_pin="x.x") }} run_constrained: - arm-variant * {{ arm_variant_type }} # [aarch64] - test: - commands: - - test -L $PREFIX/lib/libcudart.so.{{ version }} # [linux] - - test -L $PREFIX/lib/libcudart.so.{{ version.split(".")[0] }} # [linux] - - test -L $PREFIX/targets/{{ target_name }}/lib/libcudart.so.{{ version }} # [linux] - - test -f $PREFIX/targets/{{ target_name }}/lib/libcudart.so.{{ version.split(".")[0] }} # [linux] - - if not exist %LIBRARY_BIN%\cudart64_{{ version.split(".")[0] }}.dll exit 1 # [win] + # Tests are defined at the top level, due to package/output name conflicts. about: home: https://developer.nvidia.com/cuda-toolkit license_file: LICENSE From 2af21405a53d6d6a02a82f317b8b8e8bbac5a3b0 Mon Sep 17 00:00:00 2001 From: adibbley <103537006+adibbley@users.noreply.github.com> Date: Tue, 11 Apr 2023 17:46:52 -0400 Subject: [PATCH 40/40] Normalize the whitespace to match the other lines like this. Co-authored-by: Bradley Dice --- recipes/cuda-cudart/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cuda-cudart/meta.yaml b/recipes/cuda-cudart/meta.yaml index e3eab819ce9c1..058845f917fd6 100644 --- a/recipes/cuda-cudart/meta.yaml +++ b/recipes/cuda-cudart/meta.yaml @@ -85,7 +85,7 @@ outputs: - {{ pin_subpackage("cuda-cudart-dev_" + target_platform, exact=True) }} - {{ pin_subpackage("cuda-cudart-static", exact=True) }} run_constrained: - - arm-variant * {{ arm_variant_type }} # [aarch64] + - arm-variant * {{ arm_variant_type }} # [aarch64] test: commands: - test -L $PREFIX/lib/libcudart.so # [linux]