Changeset View
Changeset View
Standalone View
Standalone View
intern/cycles/CMakeLists.txt
| Show First 20 Lines • Show All 307 Lines • ▼ Show 20 Lines | if(WITH_CYCLES_CUDA_BINARIES AND (NOT WITH_CYCLES_CUBIN_COMPILER)) | ||||
| if(MSVC) | if(MSVC) | ||||
| set(MAX_MSVC 1800) | set(MAX_MSVC 1800) | ||||
| if(${CUDA_VERSION} EQUAL "8.0") | if(${CUDA_VERSION} EQUAL "8.0") | ||||
| set(MAX_MSVC 1900) | set(MAX_MSVC 1900) | ||||
| elseif(${CUDA_VERSION} EQUAL "9.0") | elseif(${CUDA_VERSION} EQUAL "9.0") | ||||
| set(MAX_MSVC 1910) | set(MAX_MSVC 1910) | ||||
| elseif(${CUDA_VERSION} EQUAL "9.1") | elseif(${CUDA_VERSION} EQUAL "9.1") | ||||
| set(MAX_MSVC 1911) | set(MAX_MSVC 1911) | ||||
| elseif(${CUDA_VERSION} EQUAL "10.0") | elseif(${CUDA_VERSION} LESS "11.0") | ||||
| set(MAX_MSVC 1999) | |||||
| elseif(${CUDA_VERSION} EQUAL "10.1") | |||||
| set(MAX_MSVC 1999) | set(MAX_MSVC 1999) | ||||
| endif() | endif() | ||||
| if(NOT MSVC_VERSION LESS ${MAX_MSVC} OR CMAKE_C_COMPILER_ID MATCHES "Clang") | if(NOT MSVC_VERSION LESS ${MAX_MSVC} OR CMAKE_C_COMPILER_ID MATCHES "Clang") | ||||
| message(STATUS "nvcc not supported for this compiler version, using cycles_cubin_cc instead.") | message(STATUS "nvcc not supported for this compiler version, using cycles_cubin_cc instead.") | ||||
| set(WITH_CYCLES_CUBIN_COMPILER ON) | set(WITH_CYCLES_CUBIN_COMPILER ON) | ||||
| endif() | endif() | ||||
| unset(MAX_MSVC) | unset(MAX_MSVC) | ||||
| elseif(APPLE) | elseif(APPLE) | ||||
| if(NOT (${XCODE_VERSION} VERSION_LESS 10.0)) | if(NOT (${XCODE_VERSION} VERSION_LESS 10.0)) | ||||
| message(STATUS "nvcc not supported for this compiler version, using cycles_cubin_cc instead.") | message(STATUS "nvcc not supported for this compiler version, using cycles_cubin_cc instead.") | ||||
| set(WITH_CYCLES_CUBIN_COMPILER ON) | set(WITH_CYCLES_CUBIN_COMPILER ON) | ||||
| endif() | endif() | ||||
| endif() | endif() | ||||
| endif() | endif() | ||||
| # NVRTC gives wrong rendering result in CUDA 10.0, so we must use NVCC. | # NVRTC gives wrong rendering result in CUDA 10.0, so we must use NVCC. | ||||
| if(WITH_CYCLES_CUDA_BINARIES AND WITH_CYCLES_CUBIN_COMPILER) | if(WITH_CYCLES_CUDA_BINARIES AND WITH_CYCLES_CUBIN_COMPILER AND NOT WITH_CYCLES_CUBIN_COMPILER_OVERRRIDE) | ||||
| if(NOT (${CUDA_VERSION} VERSION_LESS 10.0)) | if(NOT (${CUDA_VERSION} VERSION_LESS 10.0)) | ||||
| message(STATUS "cycles_cubin_cc not supported for CUDA 10.0+, using nvcc instead.") | message(STATUS "cycles_cubin_cc not supported for CUDA 10.0+, using nvcc instead.") | ||||
| set(WITH_CYCLES_CUBIN_COMPILER OFF) | set(WITH_CYCLES_CUBIN_COMPILER OFF) | ||||
| endif() | endif() | ||||
| endif() | endif() | ||||
| # Subdirectories | # Subdirectories | ||||
| Show All 30 Lines | |||||