Skip to content

Commit

Permalink
Use conda compilers (#2101)
Browse files Browse the repository at this point in the history
This PR enables the usage of conda compilers to build conda packages. This is required to use `mambabuild`

Authors:
  - Jordan Jacobelli (https://github.com/Ethyling)

Approvers:
  - AJ Schmidt (https://github.com/ajschmidt8)
  - Rick Ratzel (https://github.com/rlratzel)

URL: #2101
  • Loading branch information
jjacobelli authored May 23, 2022
1 parent 2e23132 commit 9b1d189
Show file tree
Hide file tree
Showing 7 changed files with 59 additions and 10 deletions.
11 changes: 11 additions & 0 deletions conda/recipes/cugraph/conda_build_config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
c_compiler_version:
- 9

cxx_compiler_version:
- 9

cuda_compiler:
- nvcc

sysroot_version:
- "2.17"
10 changes: 7 additions & 3 deletions conda/recipes/cugraph/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,17 @@ build:
number: {{ GIT_DESCRIBE_NUMBER }}
string: cuda{{ cuda_major }}_py{{ py_version }}_{{ GIT_DESCRIBE_HASH }}_{{ GIT_DESCRIBE_NUMBER }}
script_env:
- CC
- CXX
- CUDAHOSTCXX
- PARALLEL_LEVEL
ignore_run_exports_from:
- {{ compiler('cuda') }}

requirements:
build:
- {{ compiler('c') }}
- {{ compiler('cxx') }}
- {{ compiler('cuda') }} {{ cuda_version }}
- sysroot_{{ target_platform }} {{ sysroot_version }}
host:
- python x.x
- cython>=0.29,<0.30
- libcugraph={{ version }}
Expand Down
12 changes: 12 additions & 0 deletions conda/recipes/libcugraph/conda_build_config.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
c_compiler_version:
- 9

cxx_compiler_version:
- 9

cuda_compiler:
- nvcc

cmake_version:
- ">=3.20.1,!=3.23.0"

Expand All @@ -15,3 +24,6 @@ gtest_version:

libcusolver_version:
- ">=11.2.1"

sysroot_version:
- "2.17"
13 changes: 10 additions & 3 deletions conda/recipes/libcugraph/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@ source:

build:
script_env:
- CC
- CXX
- CUDAHOSTCXX
- PARALLEL_LEVEL
- VERSION_SUFFIX
- CMAKE_GENERATOR
Expand All @@ -34,6 +31,10 @@ build:
requirements:
build:
- cmake {{ cmake_version }}
- {{ compiler('c') }}
- {{ compiler('cxx') }}
- {{ compiler('cuda') }} {{ cuda_version }}
- sysroot_{{ target_platform }} {{ sysroot_version }}
host:
- doxygen {{ doxygen_version }}
- cudatoolkit {{ cuda_version }}.*
Expand All @@ -54,6 +55,8 @@ outputs:
build:
number: {{ GIT_DESCRIBE_NUMBER }}
string: cuda{{ cuda_major }}_{{ GIT_DESCRIBE_HASH }}_{{ GIT_DESCRIBE_NUMBER }}
ignore_run_exports_from:
- {{ compiler('cuda') }}
requirements:
build:
- cmake {{ cmake_version }}
Expand All @@ -76,6 +79,8 @@ outputs:
build:
number: {{ GIT_DESCRIBE_NUMBER }}
string: cuda{{ cuda_major }}_{{ GIT_DESCRIBE_HASH }}_{{ GIT_DESCRIBE_NUMBER }}
ignore_run_exports_from:
- {{ compiler('cuda') }}
requirements:
build:
- cmake {{ cmake_version }}
Expand All @@ -96,6 +101,8 @@ outputs:
build:
number: {{ GIT_DESCRIBE_NUMBER }}
string: cuda{{ cuda_major }}_{{ GIT_DESCRIBE_HASH }}_{{ GIT_DESCRIBE_NUMBER }}
ignore_run_exports_from:
- {{ compiler('cuda') }}
requirements:
build:
- cmake {{ cmake_version }}
Expand Down
11 changes: 11 additions & 0 deletions conda/recipes/pylibcugraph/conda_build_config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
c_compiler_version:
- 9

cxx_compiler_version:
- 9

cuda_compiler:
- nvcc

sysroot_version:
- "2.17"
10 changes: 7 additions & 3 deletions conda/recipes/pylibcugraph/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,17 @@ build:
number: {{ GIT_DESCRIBE_NUMBER }}
string: cuda{{ cuda_major }}_py{{ py_version }}_{{ GIT_DESCRIBE_HASH }}_{{ GIT_DESCRIBE_NUMBER }}
script_env:
- CC
- CXX
- CUDAHOSTCXX
- PARALLEL_LEVEL
ignore_run_exports_from:
- {{ compiler('cuda') }}

requirements:
build:
- {{ compiler('c') }}
- {{ compiler('cxx') }}
- {{ compiler('cuda') }} {{ cuda_version }}
- sysroot_{{ target_platform }} {{ sysroot_version }}
host:
- python x.x
- cython>=0.29,<0.30
- libcugraph={{ version }}
Expand Down
2 changes: 1 addition & 1 deletion python/pylibcugraph/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ def run(self):
os.path.join(os.sys.prefix, "lib")
],
libraries=['cudart', 'cusparse', 'cusolver', 'cugraph', 'nccl',
'cugraph_c'],
'cugraph_c', 'cublas'],
language='c++',
extra_compile_args=['-std=c++17'])
]
Expand Down

0 comments on commit 9b1d189

Please sign in to comment.