Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding cuda-cccl recipe #21953

Merged
merged 24 commits into from
Apr 7, 2023
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
e23c82c
Adding cuda-cccl recipe
adibbley Feb 3, 2023
54b6f81
Only link contents of cmake directory
adibbley Feb 14, 2023
84a3ae4
Split outputs to include cuda-cccl_{{ target_platform }}
adibbley Feb 14, 2023
78a86ba
Update for linter
adibbley Feb 14, 2023
dcebfc9
Fix Windows build
adibbley Feb 14, 2023
b88abad
Merge branch 'main' into cuda-cccl
jakirkham Mar 14, 2023
91cb174
Using nvcc targets for Windows
adibbley Mar 24, 2023
9894ddc
Merge branch 'main' into cuda-cccl
jakirkham Mar 27, 2023
6384fd0
Adding cuda-cccl-impl to align with GitHub repos
adibbley Mar 28, 2023
069203c
Add version tags for thrust/cub/libcudacxx
adibbley Mar 28, 2023
49fd69f
Require exact cuda-cccl-impl version
adibbley Mar 28, 2023
1346eda
Apply suggestions from code review
adibbley Mar 31, 2023
85fe668
Add jinja variable for impl version
adibbley Mar 31, 2023
863f6ca
Apply suggestions from code review
adibbley Mar 31, 2023
641a75f
Updates following libcublas
adibbley Apr 3, 2023
9fa726d
Remove extra extras
adibbley Apr 3, 2023
7e4326c
Apply suggestions from code review
adibbley Apr 4, 2023
edce83d
Add arm-variant sbsa
adibbley Apr 4, 2023
d7b7282
Apply suggestions from code review
adibbley Apr 5, 2023
504f9cb
Fix lint
adibbley Apr 5, 2023
dff5087
Fix lint
adibbley Apr 5, 2023
f117e5c
Remove constraint, cub/thrust should instead conflict with this pacakge
adibbley Apr 5, 2023
b99e9ec
Update recipes/cuda-cccl-impl/meta.yaml
adibbley Apr 5, 2023
cfcbb8c
Copy comment description from cuda-cccl-impl
adibbley Apr 5, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions recipes/cuda-cccl-impl/bld.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
if not exist %PREFIX% mkdir %PREFIX%
mkdir %LIBRARY_LIB%\cmake
mkdir %LIBRARY_INC%

move thrust\thrust\cmake %LIBRARY_LIB%\cmake\thrust
move cub\cub\cmake %LIBRARY_LIB%\cmake\cub
move libcudacxx\lib\cmake\libcudacxx %LIBRARY_LIB%\cmake

move thrust\thrust %LIBRARY_INC%
move cub\cub %LIBRARY_INC%
move libcudacxx\include\cuda %LIBRARY_INC%
move libcudacxx\include\nv %LIBRARY_INC%
13 changes: 13 additions & 0 deletions recipes/cuda-cccl-impl/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/bash

mkdir -p ${PREFIX}/lib/cmake
mkdir -p ${PREFIX}/include

mv -v thrust/thrust/cmake ${PREFIX}/lib/cmake/thrust
mv -v cub/cub/cmake ${PREFIX}/lib/cmake/cub
cp -rv libcudacxx/lib/cmake/libcudacxx ${PREFIX}/lib/cmake

cp -rv thrust/thrust ${PREFIX}/include
cp -rv cub/cub ${PREFIX}/include
cp -rv libcudacxx/include/cuda ${PREFIX}/include
cp -rv libcudacxx/include/nv ${PREFIX}/include
67 changes: 67 additions & 0 deletions recipes/cuda-cccl-impl/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
{% set name = "cuda-cccl-impl" %}
{% set version = "2.0.1" %}
{% set thrust_version = "2.0.1" %}
{% set cub_version = "2.0.1" %}
{% set libcudacxx_version = "1.9.0" %}
{% 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.gz" %} # [not win]
{% set extension = "zip" %} # [win]

package:
adibbley marked this conversation as resolved.
Show resolved Hide resolved
name: {{ name|lower }}
version: {{ version }}

source:
- url: https://github.com/NVIDIA/thrust/archive/refs/tags/{{ thrust_version }}.{{ extension }}
folder: thrust
sha256: 06df373cf487cf3710be6798bc5441a03685b78e5c1338e2f14005f7ccd030e6 # [linux]
sha256: 39a9fc88b0b06da118cc3ed28cbfca27b2a7ae192877996cab1295176ceed65e # [win]
- url: https://github.com/NVIDIA/cub/archive/refs/tags/{{ cub_version }}.{{ extension }}
folder: cub
sha256: beeef0962c87eca994db06cb9e9168a71c63fb369398a5b5f1db923140814701 # [linux]
sha256: 22308facf62421d6dd2489b9554ffa4908dca13d3921a3e7f2965c5a6984cd20 # [win]
- url: https://github.com/NVIDIA/libcudacxx/archive/refs/tags/{{ libcudacxx_version }}.{{ extension }}
folder: libcudacxx
sha256: 05b1435ad65f5bdef1bb8d1eb29dc8f0f7df34c01d77bf8686687a4603588bce # [linux]
sha256: d7864460ce8def8e0620cb9dd891e94299ade75eac75aa96b34001af3cdb074c # [win]
kkraus14 marked this conversation as resolved.
Show resolved Hide resolved

build:
number: 0
skip: true # [osx]

adibbley marked this conversation as resolved.
Show resolved Hide resolved
test:
commands:
- test -d $PREFIX/lib/cmake/thrust # [linux]
- test -d $PREFIX/lib/cmake/cub # [linux]
- test -d $PREFIX/lib/cmake/libcudacxx # [linux]
- test -d $PREFIX/include/thrust # [linux]
- test -d $PREFIX/include/cub # [linux]
- test -d $PREFIX/include/cuda # [linux]
- test -d $PREFIX/include/nv # [linux]
- if not exist %LIBRARY_LIB%\cmake\thrust exit 1 # [win]
- if not exist %LIBRARY_LIB%\cmake\cub exit 1 # [win]
- if not exist %LIBRARY_LIB%\cmake\libcudacxx exit 1 # [win]
- if not exist %LIBRARY_INC%\thrust exit 1 # [win]
- if not exist %LIBRARY_INC%\cub exit 1 # [win]
- if not exist %LIBRARY_INC%\cuda exit 1 # [win]
- if not exist %LIBRARY_INC%\nv exit 1 # [win]

about:
home: https://developer.nvidia.com/cuda-toolkit
license_file:
- cub/LICENSE.TXT
- thrust/LICENSE
- libcudacxx/LICENSE.TXT
license: BSD-3-Clause AND Apache-2.0
license_url: https://docs.nvidia.com/cuda/eula/index.html
summary: 'CUDA C++ Core Libraries'
description: |
CUDA C++ Core Libraries
doc_url: https://docs.nvidia.com/cuda/index.html

extra:
recipe-maintainers:
- adibbley
10 changes: 10 additions & 0 deletions recipes/cuda-cccl/bld.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
if not exist %PREFIX% mkdir %PREFIX%
mkdir %LIBRARY_LIB%\x64
mkdir %LIBRARY_INC%\targets
mkdir %LIBRARY_INC%\targets\x64

move lib\cmake %LIBRARY_LIB%\x64
move include\cub %LIBRARY_INC%\targets\x64
move include\cuda %LIBRARY_INC%\targets\x64
move include\nv %LIBRARY_INC%\targets\x64
move include\thrust %LIBRARY_INC%\targets\x64
13 changes: 13 additions & 0 deletions recipes/cuda-cccl/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/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"

mkdir -p ${PREFIX}/${targetsDir}

cp -rv lib ${PREFIX}/${targetsDir}
cp -rv include ${PREFIX}/${targetsDir}
2 changes: 2 additions & 0 deletions recipes/cuda-cccl/conda_build_config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
arm_variant_type: # [aarch64]
- sbsa # [aarch64]
102 changes: 102 additions & 0 deletions recipes/cuda-cccl/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
{% set name = "cuda-cccl" %}
{% set version = "12.0.90" %}
{% set impl_version = "2.0.1" %}
{% set cuda_version = "12.0" %}
{% set platform = "linux-x86_64" %} # [linux64]
{% 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]

package:
name: {{ name|lower }}
version: {{ version }}

source:
url: https://developer.download.nvidia.com/compute/cuda/redist/cuda_cccl/{{ platform }}/cuda_cccl-{{ platform }}-{{ version }}-archive.{{ extension }}
sha256: 37f6e03b6f95579d8e2e96b9ba15eeb1224dcd18b21ad50c3ac249e408152a24 # [linux64]
sha256: c6de67acd6a65b24db0383f6330b842ed19b6c27a27a37f828e9f3e96cc96f72 # [ppc64le]
sha256: f2a19927c558a9c872fa87eda4c0dc0446e5c4c744df4f846d01f4d4e08c8cd7 # [aarch64]
sha256: dd422d4cc8462d112411659a56cc78cb6010d704f83db3e48c55a3f66eed5ec2 # [win]

build:
number: 0
skip: true # [osx]

outputs:
- name: cuda-cccl
requirements:
build:
- arm-variant * {{ arm_variant_type }} # [aarch64]
host:
- cuda-version {{ cuda_version }}
run:
- {{ pin_compatible("cuda-version", max_pin="x.x") }}
- cuda-cccl_{{ target_platform }} =={{ version }}
kkraus14 marked this conversation as resolved.
Show resolved Hide resolved
- cuda-cccl-impl =={{ impl_version }}
adibbley marked this conversation as resolved.
Show resolved Hide resolved
run_constrained:
- arm-variant * {{ arm_variant_type }} # [aarch64]
test:
commands:
- test -d $PREFIX/targets/{{ target_name }}/lib # [linux]
- test -d $PREFIX/lib/cmake # [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 C++ Core Libraries'
description: |
CUDA C++ Core Libraries
doc_url: https://docs.nvidia.com/cuda/index.html

- name: cuda-cccl_{{ target_platform }}
build:
noarch: generic
files:
- targets # [linux]
- Library\lib\x64\cmake # [win]
- Library\include\targets\{{ target_name }} # [win]
requirements:
build:
- arm-variant * {{ arm_variant_type }} # [aarch64]
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 -d $PREFIX/targets/{{ target_name }}/lib # [linux]
- test -d $PREFIX/targets/{{ target_name }}/include # [linux]
- if not exist %LIBRARY_LIB%\{{ target_name }}\cmake exit 1 # [win]
- if not exist %LIBRARY_INC%\targets\{{ target_name }} 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 C++ Core Libraries'
description: |
CUDA C++ Core Libraries
doc_url: https://docs.nvidia.com/cuda/index.html

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 C++ Core Libraries'
description: |
CUDA C++ Core Libraries
doc_url: https://docs.nvidia.com/cuda/index.html

extra:
recipe-maintainers:
- adibbley