mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-13 05:20:45 +00:00
Fix Vulkan-only build
NVIDIA counters build assumed Vulkan build implies GL build. This is not necessarily the case.
This commit is contained in:
committed by
Baldur Karlsson
parent
70df111a5e
commit
c86e8d2446
@@ -565,7 +565,7 @@ if(ENABLE_GL OR ENABLE_GLES)
|
||||
endif()
|
||||
|
||||
# pull in the NVIDIA folder
|
||||
if(NOT ANDROID AND NOT APPLE AND (ENABLE_GL OR ENABLE_GLES))
|
||||
if(NOT ANDROID AND NOT APPLE AND (ENABLE_GL OR ENABLE_GLES OR ENABLE_VULKAN))
|
||||
add_subdirectory(driver/ihv/nv)
|
||||
list(APPEND renderdoc_objects $<TARGET_OBJECTS:rdoc_nv>)
|
||||
endif()
|
||||
|
||||
@@ -1,16 +1,22 @@
|
||||
set(sources
|
||||
nv_counter_enumerator.cpp
|
||||
nv_counter_enumerator.h
|
||||
nv_gl_counters.cpp
|
||||
nv_gl_counters.h
|
||||
nv_vk_counters.cpp
|
||||
nv_vk_counters.h)
|
||||
|
||||
if(ENABLE_GL OR ENABLE_GLES)
|
||||
set(sources_gl nv_gl_counters.cpp)
|
||||
endif()
|
||||
|
||||
if(ENABLE_VULKAN)
|
||||
set(sources_vulkan nv_vk_counters.cpp)
|
||||
endif()
|
||||
|
||||
set(include_dirs
|
||||
${RDOC_INCLUDES}
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/official/PerfSDK/redist/include"
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/official/PerfSDK/redist/NvPerfUtility/include")
|
||||
|
||||
add_library(rdoc_nv OBJECT ${sources})
|
||||
add_library(rdoc_nv OBJECT ${sources} ${sources_gl} ${sources_vulkan})
|
||||
target_compile_definitions(rdoc_nv ${RDOC_DEFINITIONS})
|
||||
target_include_directories(rdoc_nv ${include_dirs})
|
||||
|
||||
Reference in New Issue
Block a user