Description
When i try to install pyopencl with pip on windows 11 or windows 10, it fails and raises this error:
Building wheels for collected packages: pyopencl
Building wheel for pyopencl (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for pyopencl (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [80 lines of output]
*** scikit-build-core 0.10.7 using CMake 3.29.3 (wheel)
*** Configuring CMake...
loading initial cache file C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\CMakeInit.txt
-- Building for: Visual Studio 17 2022
-- Selecting Windows SDK version 10.0.22621.0 to target Windows 10.0.22631.
-- The CXX compiler identification is MSVC 19.41.34123.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.41.34120/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- CL_INC_DIR not set, trying to guess it from environment variables.
-- CL_INC_DIR not set, trying to guess it from conda environment.
-- CL_INC_DIR
-- CL_LIB_DIR
-- CL_LIBNAME
-- Found Python: D:\AA_CODING\python\Projects\AA_MFSIG\StackingCL\Scripts\python.exe (found version "3.13.0") found components: Interpreter Development.Module NumPy
'D:\AA_CODING\python\Projects\AA_MFSIG\StackingCL\Scripts\python.exe' '-c' 'import nanobind; print(nanobind.__version__)'
'D:\AA_CODING\python\Projects\AA_MFSIG\StackingCL\Scripts\python.exe' '-c' 'import nanobind; print(nanobind.cmake_dir())'
-- Looking for CL_VERSION_3_0
-- Looking for CL_VERSION_3_0 - found
-- Found OpenCL: C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.0/lib/x64/OpenCL.lib (found version "3.0")
==============================
PyOpenCL v2024.3 (non-git) configuration:
PyOpenCL options: PYOPENCL_TRACE=OFF PYOPENCL_ENABLE_GL=OFF PYOPENCL_USE_SHIPPED_EXT=OFF PYOPENCL_PRETEND_CL_VERSION=
OpenCL: C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.0/lib/x64/OpenCL.lib [3.0]
Python: D:\AA_CODING\python\Projects\AA_MFSIG\StackingCL\Scripts\python.exe [3.13.0]
Build type:
C++ compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.41.34120/bin/Hostx64/x64/cl.exe [MSVC 19.41.34123.0]
CMake: C:/Program Files/CMake/bin/cmake.exe [3.29.3]
Nanobind: C:\Users\bubig\AppData\Local\Temp\pip-build-env-s75_6929\overlay\Lib\site-packages\nanobind\cmake [2.2.0]
Build tool: C:/Program Files/Microsoft Visual Studio/2022/Community/MSBuild/Current/Bin/amd64/MSBuild.exe
==============================
-- Configuring done (2.7s)
-- Generating done (0.0s)
-- Build files have been written to: C:/Users/bubig/AppData/Local/Temp/tmpl9e7eg40/build
*** Building project with Visual Studio 17 2022...
MSBuild version 17.11.9+a69bbaaf5 for .NET Framework
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppBuild.targets(541,5): warning MSB8029: The Intermediate directory or Output directory cannot reside under the Temporary directory as it could lead to issues with incremental build. [C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\ZERO_CHECK.vcxproj]
1>Checking Build System
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppBuild.targets(541,5): warning MSB8029: The Intermediate directory or Output directory cannot reside under the Temporary directory as it could lead to issues with incremental build. [C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\nanobind-static.vcxproj]
Building Custom Rule C:/Users/bubig/AppData/Local/Temp/pip-install-3vk6j_i5/pyopencl_b8e68b964c3142aca873a04dbbc62b1d/CMakeLists.txt
nb_internals.cpp
nb_func.cpp
nb_type.cpp
nb_enum.cpp
nb_ndarray.cpp
nb_static_property.cpp
common.cpp
error.cpp
trampoline.cpp
implicit.cpp
Generating Code...
nanobind-static.vcxproj -> C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\Release\nanobind-static.lib
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppBuild.targets(541,5): warning MSB8029: The Intermediate directory or Output directory cannot reside under the Temporary directory as it could lead to issues with incremental build. [C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\_cl.vcxproj]
Building Custom Rule C:/Users/bubig/AppData/Local/Temp/pip-install-3vk6j_i5/pyopencl_b8e68b964c3142aca873a04dbbc62b1d/CMakeLists.txt
wrap_constants.cpp
wrap_cl.cpp
wrap_cl_part_1.cpp
wrap_cl_part_2.cpp
wrap_mempool.cpp
bitlog.cpp
C:\Users\bubig\AppData\Local\Temp\pip-install-3vk6j_i5\pyopencl_b8e68b964c3142aca873a04dbbc62b1d\src\wrap_cl.hpp(70,10): error C1083: Cannot open include file: 'CL/cl.h': No such file or directory [C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\_cl.vcxproj]
(compiling source file '../../pip-install-3vk6j_i5/pyopencl_b8e68b964c3142aca873a04dbbc62b1d/src/wrap_cl.cpp')
C:\Users\bubig\AppData\Local\Temp\pip-install-3vk6j_i5\pyopencl_b8e68b964c3142aca873a04dbbc62b1d\src\wrap_cl.hpp(70,10): error C1083: Cannot open include file: 'CL/cl.h': No such file or directory [C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\_cl.vcxproj]
(compiling source file '../../pip-install-3vk6j_i5/pyopencl_b8e68b964c3142aca873a04dbbc62b1d/src/wrap_constants.cpp')
C:\Users\bubig\AppData\Local\Temp\pip-install-3vk6j_i5\pyopencl_b8e68b964c3142aca873a04dbbc62b1d\src\wrap_cl.hpp(70,10): error C1083: Cannot open include file: 'CL/cl.h': No such file or directory [C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\_cl.vcxproj]
(compiling source file '../../pip-install-3vk6j_i5/pyopencl_b8e68b964c3142aca873a04dbbc62b1d/src/wrap_cl_part_1.cpp')
C:\Users\bubig\AppData\Local\Temp\pip-install-3vk6j_i5\pyopencl_b8e68b964c3142aca873a04dbbc62b1d\src\wrap_cl.hpp(70,10): error C1083: Cannot open include file: 'CL/cl.h': No such file or directory [C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\_cl.vcxproj]
(compiling source file '../../pip-install-3vk6j_i5/pyopencl_b8e68b964c3142aca873a04dbbc62b1d/src/wrap_cl_part_2.cpp')
C:\Users\bubig\AppData\Local\Temp\pip-install-3vk6j_i5\pyopencl_b8e68b964c3142aca873a04dbbc62b1d\src\wrap_cl.hpp(70,10): error C1083: Cannot open include file: 'CL/cl.h': No such file or directory [C:\Users\bubig\AppData\Local\Temp\tmpl9e7eg40\build\_cl.vcxproj]
(compiling source file '../../pip-install-3vk6j_i5/pyopencl_b8e68b964c3142aca873a04dbbc62b1d/src/wrap_mempool.cpp')
*** CMake build failed
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pyopencl
Failed to build pyopencl
ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (pyopencl)
To Reproduce
Steps to reproduce the behavior:
- Install python3.13 (i always installed 3.13t too)
- select 3.13 or 3.13t as your interpreter
- install pyopencl using
py -m pip install pyopencl
- See error above shown
Environment (please complete the following information):
- OS: Windows 10/11
- ICD Loader and version: [e.g. ocl-icd 2.3.1]
- ICD and version: [e.g. pocl 1.8]
- CPU/GPU: Ryzen 7 3800x with 2060OC / Intel i7 7th gen with 940mx / intel 640
- Python version: 3.13 / 3.13t
- PyOpenCL version: latest (2024.3)
Is pyopencl even supported on 3.13? I couldn't find any concrete information on that, neither in forums, pypi nor here on github.
Description
When i try to install pyopencl with pip on windows 11 or windows 10, it fails and raises this error:
To Reproduce
Steps to reproduce the behavior:
py -m pip install pyopenclEnvironment (please complete the following information):
Is pyopencl even supported on 3.13? I couldn't find any concrete information on that, neither in forums, pypi nor here on github.