Skip to content

Commit

Permalink
Use glibc version from conda package for tagging wheel
Browse files Browse the repository at this point in the history
  • Loading branch information
ZzEeKkAa committed May 7, 2024
1 parent a1e81b8 commit c0dfdc1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
6 changes: 5 additions & 1 deletion conda-recipe/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ echo "--gcc-toolchain=${BUILD_PREFIX} --sysroot=${BUILD_PREFIX}/${HOST}/sysroot
ICPXCFG="$(pwd)/icpx_for_conda.cfg"
ICXCFG="$(pwd)/icpx_for_conda.cfg"

read -r GLIBC_MAJOR GLIBC_MINOR <<<"$(conda list '^sysroot_linux-64$' \
| tail -n 1 | awk '{print $2}' | grep -oP '\d+' | head -n 2 | tr '\n' ' ')"

export ICXCFG
export ICPXCFG

Expand All @@ -26,7 +29,8 @@ export PATH=$CONDA_PREFIX/bin-llvm:$PATH
# -wnx flags mean: --wheel --no-isolation --skip-dependency-check
${PYTHON} -m build -w -n -x
${PYTHON} -m wheel tags --remove --build "$GIT_DESCRIBE_NUMBER" \
--platform-tag manylinux_2_28_x86_64 dist/numba_dpex*.whl
--platform-tag "manylinux_${GLIBC_MAJOR}_${GLIBC_MINOR}_x86_64" \
dist/numba_dpex*.whl
${PYTHON} -m pip install dist/numba_dpex*.whl \
--no-build-isolation \
--no-deps \
Expand Down
7 changes: 4 additions & 3 deletions conda-recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,10 @@ requirements:
- {{ compiler('cxx') }}
- {{ compiler('dpcpp') }} >={{ required_compiler_version }},!={{ excluded_compiler_version1 }},!={{ excluded_compiler_version2 }},!={{ excluded_compiler_version3 }} # [win]
- {{ compiler('dpcpp') }} >={{ required_compiler_version }},!={{ excluded_compiler_version1 }},!={{ excluded_compiler_version2 }} # [linux]
# specific version of sysroot required by dpcpp, but 2024.0.0 package
# does not have it in meta data
- sysroot_linux-64 >=2.28 # [linux]
# Minimal supported version of sysroot (which is version of glibc) to
# have compatibility with wider range of linux distributions.
# 2.28 is the minimal supported version by dpcpp
- sysroot_linux-64 =2.28 # [linux]
host:
- python
- pip >=24.0
Expand Down

0 comments on commit c0dfdc1

Please sign in to comment.