-
-
Notifications
You must be signed in to change notification settings - Fork 10
/
meta.yaml
109 lines (102 loc) · 3.78 KB
/
meta.yaml
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
{% set name = "cuda-python" %}
{% set version = "12.6.1" %}
{% set major_version = version.split(".")[0]|int %}
{% set minor_version = version.split(".")[1]|int %}
{% set patch_version = version.split(".")[2]|int %}
{% set target_name = "x86_64-linux" %} # [linux64]
{% set target_name = "sbsa-linux" %} # [aarch64]
{% set target_name = "x64" %} # [win64]
{% set subdir = os.sep.join(["", "targets", target_name]) %} # [linux64 or aarch64]
{% set subdir = os.sep.join(["", "Library"]) %} # [win64]
package:
name: {{ name|lower }}
version: {{ version }}
source:
url: https://github.com/NVIDIA/cuda-python/archive/refs/tags/v{{ version }}.tar.gz
sha256: 07ce07b02e726f59dc2cd333d3b195df960ecfa4fbe47bbfdbb2541f7485c3d6
build:
number: 0
{% if not (environ.get("cuda_compiler_version")|string()) == (major_version|string()) %}
skip: true
{% endif %}
# `linux_ppc64le` is unsupported by the CUDA Toolkit as of 12.5.0.
# So skip building `cuda-python` on `linux_ppc64le`
# xref: https://github.com/conda-forge/cuda-feedstock/issues/27
skip: true # [ppc64le]
script:
- pushd cuda
- {{ PYTHON }} -m pip install . --no-deps -vv
script_env:
# Ensure that CUDA includes can be found by the host compiler
- CUDA_HOME={{ PREFIX ~ subdir ~ os.pathsep ~ BUILD_PREFIX ~ subdir }}
run_exports:
- {{ pin_subpackage('cuda-python', min_pin='x', max_pin='x') }}
ignore_run_exports_from:
- {{ compiler('cuda') }}
# The run-exports from these dev packages are too tight, so we ignore them.
# The cuda-python package supports CUDA Enhanced Compatibility through its
# use of dlopen, so it is compatible with other CUDA minor versions.
- cuda-cudart-dev
- cuda-nvrtc-dev
requirements:
build:
- {{ compiler('c') }}
- {{ compiler('cxx') }}
- {{ compiler('cuda') }}
- {{ stdlib('c') }}
- cross-python_{{ target_platform }} # [build_platform != target_platform]
- python # [build_platform != target_platform]
- cython # [build_platform != target_platform]
- cuda-version {{ major_version }}.{{ minor_version }}
host:
- cuda-version {{ major_version }}.{{ minor_version }}
- cuda-cudart-dev
- cuda-cudart
- cuda-nvrtc-dev
- cuda-nvrtc
- cuda-profiler-api
- cython
- pip
- pyclibrary
- python
- setuptools
- tomli # [py<311]
- versioneer
run:
- python
- {{ pin_compatible('cuda-version', min_pin='x', max_pin='x') }}
# cuda-python requires cuda-nvrtc from the same major version. We ignored
# run-exports of cuda-nvrtc-dev and instead allow a looser pinning here.
- {{ pin_compatible('cuda-nvrtc', min_pin='x', max_pin='x') }}
- pywin32 # [win64]
run_constrained:
# cuda-cudart is not a hard dependency because cuda-python re-implements
# cudart. This package is optionally dlopen'd for getting the local cudart
# version with cuda.cudart.getLocalRuntimeVersion(). We ignored run-exports
# of cuda-cudart-dev and instead allow a looser pinning here.
- {{ pin_compatible('cuda-cudart', min_pin='x', max_pin='x') }}
test:
imports:
- cuda
- cuda.cuda
- cuda.cudart
about:
home: https://github.com/NVIDIA/cuda-python
license: LicenseRef-NVIDIA-SOFTWARE-LICENSE
license_file: LICENSE
license_url: https://github.com/NVIDIA/cuda-python/blob/main/LICENSE
summary: CUDA Python Low-level Bindings
description: |
CUDA Python provides a standard set of low-level interfaces,
providing full coverage of and access to the CUDA host APIs from Python.
doc_url: https://nvidia.github.io/cuda-python/
dev_url: https://github.com/NVIDIA/cuda-python
extra:
recipe-maintainers:
- bdice
- jakirkham
- leofang
- m3vaz
- mmccarty
- vyasr
- vzhurba01