You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Building slatergpu as a pixi source dependency (git-main, currently a7f971f) fails to compile the GPU library because nvc++ cannot find cublas_v2.h / cusolverDn.h:
"…/include/cuda_util.h", line 11: catastrophic error: cannot open source file "cublas_v2.h"
#include <cublas_v2.h>
^
1 catastrophic error detected in the compilation of "…/src/integrals/cuda_util.cpp".
Compilation terminated.
Every GPU-path translation unit (cuda_util.cpp, scf_util.cpp, integrals*.cpp, …) fails the same way. include/cuda_util.h:11 pulls in <cublas_v2.h> / <cusolverDn.h> under #if USE_ACC.
Reported by multiple group members recently while building "the same way as before" — consistent with the umbrella in #95 (git-main build fails, local-path workaround). This issue documents the cuBLAS/cuSolver facet with a fully-traced root cause.
Root cause — environment, not the repo
nvc++ locates the CUDA math-library headers via the NVHPC module environment (module load nvhpc sets CPATH=…/math_libs/include). The pixi build sandbox runs nvc++ with that environment stripped, so the headers are unreachable. Confirmed both directions on athena (NVHPC 25.5, nvc++ 25.5-0; pixi 0.70.2):
The header itself is present (…/nvidia_hpc_sdk/Linux_x86_64/25.5/math_libs/include/cublas_v2.h); the build just isn't told where to look.
Why a git bisect of the repos won't isolate it
The in-repo wiring hasn't changed: the <cublas_v2.h> include is long-standing, and SlaterGPU has never passed -cudalib (git log -S cudalib is empty). What flipped is whether the pixi build sandbox forwards the NVHPC/CPATH environment to nvc++ — i.e. the pixi / pixi-build-cmake toolchain, not SlaterGPU source. The useful bisect is to hold both repos fixed and vary the pixi version (0.70 ↔ 0.71), tying in with #96.
Proposed fix (repo-side, environment-independent)
Make the GPU build supply the CUDA math-lib headers itself, so it no longer depends on every developer's shell having CPATH set. Options (both validated under the stripped env above):
Add -cudalib=cublas,cusolver to the GPU target_compile_options (nvc++ then provides both include + link). Minimal, nvc++-native.
Summary
Building
slatergpuas a pixi source dependency (git-main, currentlya7f971f) fails to compile the GPU library becausenvc++cannot findcublas_v2.h/cusolverDn.h:Every GPU-path translation unit (
cuda_util.cpp,scf_util.cpp,integrals*.cpp, …) fails the same way.include/cuda_util.h:11pulls in<cublas_v2.h>/<cusolverDn.h>under#if USE_ACC.Reported by multiple group members recently while building "the same way as before" — consistent with the umbrella in #95 (git-
mainbuild fails, local-path workaround). This issue documents the cuBLAS/cuSolver facet with a fully-traced root cause.Root cause — environment, not the repo
nvc++locates the CUDA math-library headers via the NVHPC module environment (module load nvhpcsetsCPATH=…/math_libs/include). The pixi build sandbox runsnvc++with that environment stripped, so the headers are unreachable. Confirmed both directions on athena (NVHPC 25.5, nvc++ 25.5-0; pixi 0.70.2):cuda_util.cppcompileCPATHset)cannot open source file "cublas_v2.h"CPATH=…/math_libs/includere-added-cudalib=cublas,cusolver-I …/math_libs/includeThe header itself is present (
…/nvidia_hpc_sdk/Linux_x86_64/25.5/math_libs/include/cublas_v2.h); the build just isn't told where to look.Why a git bisect of the repos won't isolate it
The in-repo wiring hasn't changed: the
<cublas_v2.h>include is long-standing, and SlaterGPU has never passed-cudalib(git log -S cudalibis empty). What flipped is whether the pixi build sandbox forwards the NVHPC/CPATHenvironment tonvc++— i.e. the pixi / pixi-build-cmake toolchain, not SlaterGPU source. The useful bisect is to hold both repos fixed and vary the pixi version (0.70 ↔ 0.71), tying in with #96.Proposed fix (repo-side, environment-independent)
Make the GPU build supply the CUDA math-lib headers itself, so it no longer depends on every developer's shell having
CPATHset. Options (both validated under the stripped env above):-cudalib=cublas,cusolverto the GPUtarget_compile_options(nvc++ then provides both include + link). Minimal, nvc++-native.find_package(CUDAToolkit)and linkCUDA::cublas/CUDA::cusolver— also closes Replace deprecated FindCUDA module with find_package(CUDAToolkit) in Config.cmake.in #93 (FindCUDA → CUDAToolkit modernization).Environment
nvc++ 25.5-0), CUDA math_libs 12.9USE_ACC=ON(default GPU build)main@a7f971fRelated
mainbuilds fail for multiple members (this is the cuBLAS/cuSolver facet)find_package(CUDAToolkit)(option 2 above closes it)