Skip to content

Commit 9506386

Browse files
committed
Clean up conda-recipe and pyproject dependencies
1 parent ce0742b commit 9506386

File tree

5 files changed

+51
-35
lines changed

5 files changed

+51
-35
lines changed

conda-recipe/conda_build_config.yaml

Lines changed: 0 additions & 6 deletions
This file was deleted.

conda-recipe/meta.yaml

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ build:
1616
- WHEELS_OUTPUT_FOLDER
1717

1818
requirements:
19+
# TODO: keep in sync with /pyproject.toml
1920
build:
2021
- {{ compiler('cxx') }}
2122
- {{ compiler('dpcpp') }} >={{ required_compiler_version }},!={{ excluded_compiler_version1 }},!={{ excluded_compiler_version2 }},!={{ excluded_compiler_version3 }} # [win]
@@ -27,29 +28,36 @@ requirements:
2728
- dpcpp-cpp-rt >={{ required_compiler_version }},!={{ excluded_compiler_version1 }},!={{ excluded_compiler_version2 }},!={{ excluded_compiler_version3 }} # [win]
2829
- dpcpp-cpp-rt >={{ required_compiler_version }},!={{ excluded_compiler_version1 }},!={{ excluded_compiler_version2 }} # [linux]
2930
- python
30-
- setuptools >=63.*
31-
- scikit-build >=0.15*
32-
- ninja # [not win]
33-
- cmake >=3.26*
34-
- numba >=0.59*
35-
- dpctl >=0.16*
36-
- dpnp >=0.14*
37-
- dpcpp-llvm-spirv
38-
- wheel
31+
- setuptools >=69
32+
- scikit-build >=0.17
33+
- ninja >=1.11.1 # [not win]
34+
- cmake >=3.29
35+
- numba >=0.59
36+
- llvmlite >=0.42.0
37+
- dpctl >=0.16.1
38+
- dpnp >=0.14
39+
- numpy >=1.24
40+
# TODO: there is no 2024 release for python 3.11
41+
# - dpcpp-llvm-spirv >={{ required_compiler_version }}
42+
- dpcpp-llvm-spirv >=2023.0
43+
- wheel >=0.43
3944
run:
4045
- {{ pin_compatible('dpcpp-cpp-rt', min_pin='x.x', max_pin='x') }}
46+
- {{ pin_compatible('intel-cmplr-lib-rt', min_pin='x.x', max_pin='x') }}
47+
- {{ pin_compatible('dpcpp-llvm-spirv', min_pin='x.x', max_pin='x') }}
48+
- {{ pin_compatible('dpnp', min_pin='x.x.x', max_pin='x.x') }}
49+
- {{ pin_compatible('dpctl', min_pin='x.x.x', max_pin='x.x') }}
50+
- {{ pin_compatible('numba', min_pin='x.x.x', max_pin='x.x') }}
51+
- {{ pin_compatible('llvmlite', min_pin='x.x.x', max_pin='x.x') }}
52+
# TODO: set max pin +2 from minor version
53+
# https://numpy.org/neps/nep-0023-backwards-compatibility.html#nep23
54+
- {{ pin_compatible('numpy', min_pin='x.x.x', max_pin='x') }}
4155
- python
42-
- numba >=0.59*
43-
- dpctl >=0.16*
44-
- dpcpp-llvm-spirv
45-
- dpnp >=0.14*
46-
- packaging
4756

4857
test:
4958
requires:
5059
- pytest
5160
- pytest-cov
52-
- {{ compiler('dpcpp') }} # [not osx]
5361
- pexpect
5462

5563
about:

environment.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ dependencies:
1515
- dpnp >=0.11*
1616
- mkl >=2021.3.0 # for dpnp
1717
- dpcpp-llvm-spirv
18-
- packaging
1918
- scikit-build >=0.15*
2019
- cmake >=3.26*
2120
- pytest

pyproject.toml

Lines changed: 21 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
[build-system]
22
build-backend = "setuptools.build_meta"
33
requires = [
4-
"setuptools>=42",
5-
"scikit-build>=0.13",
6-
"cmake>=3.18",
7-
"ninja",
8-
"numba>=0.58",
9-
"versioneer-518"
4+
# TODO: keep in sync with [project.dependencies] and /conda-recipe/meta.yaml
5+
"setuptools>=63.0.0",
6+
"scikit-build>=0.17.0",
7+
"ninja>=1.11.1; platform_system!='Windows'",
8+
"cmake>=3.29.0",
9+
"numba>=0.59.0",
10+
"dpctl>=0.16.1",
11+
"numpy>=1.24.0",
12+
"wheel"
1013
]
1114

1215
[project]
@@ -24,6 +27,18 @@ classifiers = [
2427
"Operating System :: Microsoft :: Windows",
2528
"Operating System :: POSIX :: Linux"
2629
]
30+
dependencies = [
31+
# TODO: keep in sync with [build-system.requires] and /conda-recipe/meta.yaml
32+
# This restrictions are for dependabot, actual restrictions are set with
33+
# conda.
34+
# TODO: populate it during build process
35+
"numba>=0.59.0",
36+
"llvmlite>=0.42.0",
37+
"dpctl>=0.16.1",
38+
"dpnp>=0.14.0",
39+
"numpy>=1.24.0",
40+
"dpcpp_llvm_spirv>=2024.0"
41+
]
2742
description = "An extension for Numba to add data-parallel offload capability"
2843
dynamic = ["version"]
2944
keywords = [

setup.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -51,18 +51,18 @@ def to_cmake_format(version: str):
5151
# Get the project version
5252
__version__ = versioneer.get_version()
5353

54-
55-
# Set project auxilary data like readme and licence files
56-
with open("README.md", "r") as f:
57-
__readme__ = "".join(line for line in f.readlines()[12:35])
58-
59-
6054
# Main setup
6155
setup(
6256
version=__version__,
57+
# https://github.com/pypa/pip/issues/11221
58+
url="https://github.com/IntelPython/numba-dpex",
59+
# Must be passed vis setup.py:
60+
# https://github.com/scikit-build/scikit-build/issues/864
61+
# TODO: switch to pyproject toml after switching to scikit-build-core
6362
packages=find_packages("."),
63+
# Needs for examples.
64+
# TODO: change to false once move examples out of package.
6465
include_package_data=True,
65-
zip_safe=False,
6666
cmake_args=[
6767
"-DNUMBA_DPEX_VERSION:STRING={0:s}".format(
6868
to_cmake_format(str(__version__))

0 commit comments

Comments
 (0)