enoki
enoki copied to clipboard
Enoki cannot build on VS2019 16.10
16.9 works pretty good. Just to notify here if anyone have any ideas. It seems Visual studio recent update have trouble with cuda related building 0.0
What is the compiler log?
The output might be too much I will just leave the top, others are saved in the file below
the input command are
cmake --build . --config Release && copy /y lib\Release\*.pyd lib\
cmake -G "Visual Studio 16 2019" -A x64 ..
Interesting, looks like nvcc doesn't like the new standard library headers. It works fine on my machine. What's your nvcc version?
Here is mine:
$ nvcc --version
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2019 NVIDIA Corporation
Built on Wed_Oct_23_19:32:27_Pacific_Daylight_Time_2019
Cuda compilation tools, release 10.2, V10.2.89
I am currently using cuda11.0 and cuda 11.4 It seems new visual studio (16.10) have trouble building many cuda related thing
It seems new visual studio (16.10) have trouble building many cuda related thing
Have you seen similar issues with the new version of MSVC on other projects online? Maybe this will be fixed in a future version of MSVC then?
It seems new visual studio (16.10) have trouble building many cuda related thing
Have you seen similar issues with the new version of MSVC on other projects online? Maybe this will be fixed in a future version of MSVC then?
I do see some similar problems before. Haven't seen a solution so far. I think if this can't be fixed then just avoid updating 16.10 for now until some future solution appears. btw if I build enoki using 16.9 and link with my project which build using 16.10, it will also fail.
Just find this problem appears also in the old visual studio and maybe not a bug? Here are some link that might be useful https://developercommunity.visualstudio.com/t/xutility-errors-compiling-asio-and-basic-source/631347 https://stackoverflow.com/questions/67732065/why-does-vs2019-pro-have-compile-errors-with-xutility-xmemory-and-atomic-when
During the cmake building, I have this warning (not sure if this is important:
What's the spec of your machine?
I solved my Windows build problems (also CUDA 11 and VS 16.10) by changing
if (NOT CMAKE_CUDA_COMPILER_VERSION VERSION_LESS 9.0)
if(CMAKE_CUDA_SIMULATE_VERSION VERSION_GREATER_EQUAL 19.10.25017)
set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "-std=c++14")
set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "-std=c++14")
else()
set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "")
set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "")
endif()
endif()
to
if (NOT CMAKE_CUDA_COMPILER_VERSION VERSION_LESS 9.0)
if(CMAKE_CUDA_SIMULATE_VERSION VERSION_GREATER_EQUAL 19.10.25017)
#set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "-std=c++14")
#set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "-std=c++14")
else()
set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "")
set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "")
endif()
endif()
in C:\Program Files\CMake\share\cmake-3.19\Modules\Compiler\NVIDIA-CUDA.cmake
Maybe that's helpful for you
I solved my Windows build problems (also CUDA 11 and VS 16.10) by changing
if (NOT CMAKE_CUDA_COMPILER_VERSION VERSION_LESS 9.0) if(CMAKE_CUDA_SIMULATE_VERSION VERSION_GREATER_EQUAL 19.10.25017) set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "-std=c++14") set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "-std=c++14") else() set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "") set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "") endif() endif()
to
if (NOT CMAKE_CUDA_COMPILER_VERSION VERSION_LESS 9.0) if(CMAKE_CUDA_SIMULATE_VERSION VERSION_GREATER_EQUAL 19.10.25017) #set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "-std=c++14") #set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "-std=c++14") else() set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "") set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "") endif() endif()
in
C:\Program Files\CMake\share\cmake-3.19\Modules\Compiler\NVIDIA-CUDA.cmake
Maybe that's helpful for you
Thanks! this indeed works!
I solved my Windows build problems (also CUDA 11 and VS 16.10) by changing
if (NOT CMAKE_CUDA_COMPILER_VERSION VERSION_LESS 9.0) if(CMAKE_CUDA_SIMULATE_VERSION VERSION_GREATER_EQUAL 19.10.25017) set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "-std=c++14") set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "-std=c++14") else() set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "") set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "") endif() endif()
to
if (NOT CMAKE_CUDA_COMPILER_VERSION VERSION_LESS 9.0) if(CMAKE_CUDA_SIMULATE_VERSION VERSION_GREATER_EQUAL 19.10.25017) #set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "-std=c++14") #set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "-std=c++14") else() set(CMAKE_CUDA14_STANDARD_COMPILE_OPTION "") set(CMAKE_CUDA14_EXTENSION_COMPILE_OPTION "") endif() endif()
in
C:\Program Files\CMake\share\cmake-3.19\Modules\Compiler\NVIDIA-CUDA.cmake
Maybe that's helpful for you
That works for me!!!