diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2016-01-14 10:24:09 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2016-01-14 10:27:22 +0300 |
commit | 2af7637f207c420af602f43e514b1b20e7cfc718 (patch) | |
tree | 10508ea78dd73df4625119d29d00d98a81d23030 /intern/cycles/app/CMakeLists.txt | |
parent | d67535eea00b2d9f2b75e99d45f7f200bdc642d6 (diff) |
Cycles: Add option to directly link against CUDA libraries
The main purpose of such linking is to make Blender compatible with
NVidia's debuggers and profilers which are doing some LD_PRELOAD
magic to intercept some function calls. Such magic conflicts with
our CUDA wrangler magic and causes segmentation faults.
The option is disabled by default, so there's no affect on any of
artists.
In order to make Blender linked directly against CUDA library use
the WITH_CUDA_DYNLOAD CMake option (it's marked as advanced).
Diffstat (limited to 'intern/cycles/app/CMakeLists.txt')
-rw-r--r-- | intern/cycles/app/CMakeLists.txt | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/intern/cycles/app/CMakeLists.txt b/intern/cycles/app/CMakeLists.txt index 95bc517ae00..41233287279 100644 --- a/intern/cycles/app/CMakeLists.txt +++ b/intern/cycles/app/CMakeLists.txt @@ -29,9 +29,14 @@ set(LIBRARIES ${TIFF_LIBRARY} ${PTHREADS_LIBRARIES} extern_clew - extern_cuew ) +if(WITH_CUDA_DYNLOAD) + list(APPEND LIBRARIES extern_cuew) +else() + list(APPEND LIBRARIES ${CUDA_CUDA_LIBRARY}) +endif() + if(WITH_CYCLES_OSL) list(APPEND LIBRARIES cycles_kernel_osl) endif() |