compilation errors in gvdb_cutils.cu with CUDA 12
jobojeha opened this issue · 1 comments
jobojeha commented
I run into a make error when gvdb_library/CMakeFiles/gvdb.dir/src/gvdb_cutils.cu.o
is getting built.
To Reproduce
#I had to create a symlink for cmake to help it find CUDA:
sudo ln -s /usr/share/nvcc/libdevice.10.bc /usr/lib/cuda/nvvm/libdevice/.
mkdir build && cd build
cmake -DCMAKE_CUDA_COMPILER=/usr/bin/nvcc -DCMAKE_CUDA_ARCHITECTURES=86 ..
$ make
[ 2%] Built target gvdbPTX
[ 3%] Building CUDA object gvdb_library/CMakeFiles/gvdb.dir/src/gvdb_cutils.cu.o
/usr/include/cub/util_device.cuh(235): error: qualified name is not allowed
/usr/include/cub/util_device.cuh(235): error: expected a ";"
/usr/include/cub/util_device.cuh(264): error: class "cub::PerDeviceAttributeCache::DeviceEntry" has no member "flag"
/usr/include/cub/util_device.cuh(270): error: namespace "std" has no member "memory_order_acquire"
/usr/include/cub/util_device.cuh(276): error: namespace "std" has no member "memory_order_acq_rel"
/usr/include/cub/util_device.cuh(277): error: namespace "std" has no member "memory_order_acquire"
/usr/include/cub/util_device.cuh(293): error: namespace "std" has no member "memory_order_release"
/usr/include/cub/util_device.cuh(304): error: namespace "std" has no member "memory_order_acquire"
8 errors detected in the compilation of "/home/user/git/gvdb-voxels/source/gvdb_library/src/gvdb_cutils.cu".
make[2]: *** [gvdb_library/CMakeFiles/gvdb.dir/build.make:133: gvdb_library/CMakeFiles/gvdb.dir/src/gvdb_cutils.cu.o] Error 2
make[1]: *** [CMakeFiles/Makefile2:255: gvdb_library/CMakeFiles/gvdb.dir/all] Error 2
make: *** [Makefile:136: all] Error 2
Expected behavior
gvdb-voxels should compile against CUDA 12
Environment:
OS: Fedora Linux 37
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2023 NVIDIA Corporation
Built on Fri_Jan__6_16:45:21_PST_2023
Cuda compilation tools, release 12.0, V12.0.140
Build cuda_12.0.r12.0/compiler.32267302_0