externals: allow user to use system VulkanMemoryAllocator (#7149)
This commit is contained in:
parent
1c75d895fc
commit
b74c91457e
2 changed files with 14 additions and 2 deletions
13
externals/CMakeLists.txt
vendored
13
externals/CMakeLists.txt
vendored
|
@ -362,8 +362,17 @@ if (ENABLE_OPENAL)
|
|||
endif()
|
||||
|
||||
# VMA
|
||||
add_library(vma INTERFACE)
|
||||
target_include_directories(vma SYSTEM INTERFACE ./vma/include)
|
||||
if(USE_SYSTEM_VMA)
|
||||
add_library(vma INTERFACE)
|
||||
find_package(VulkanMemoryAllocator REQUIRED)
|
||||
if(TARGET GPUOpen::VulkanMemoryAllocator)
|
||||
message(STATUS "Found VulkanMemoryAllocator")
|
||||
target_link_libraries(vma INTERFACE GPUOpen::VulkanMemoryAllocator)
|
||||
endif()
|
||||
else()
|
||||
add_library(vma INTERFACE)
|
||||
target_include_directories(vma SYSTEM INTERFACE ./vma/include)
|
||||
endif()
|
||||
|
||||
# vulkan-headers
|
||||
add_library(vulkan-headers INTERFACE)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue