diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index f899312..a5e751b 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -26,20 +26,8 @@ set_target_properties( target_include_directories(VulkanMemoryAllocator PUBLIC "${PROJECT_SOURCE_DIR}/include") -if(${VMA_DYNAMIC_VULKAN_FUNCTIONS}) - set(VULKAN_USE_DYNAMIC ${VMA_DYNAMIC_VULKAN_FUNCTIONS}) -else() - set(VULKAN_USE_DYNAMIC 0) -endif() - -if(${VMA_STATIC_VULKAN_FUNCTIONS}) - set(VULKAN_USE_STATIC ${VMA_STATIC_VULKAN_FUNCTIONS}) -else() - set(VULKAN_USE_STATIC 1) -endif() - # Only link to Vulkan if static linking is used -if(${VULKAN_USE_STATIC}) +if(${VMA_STATIC_VULKAN_FUNCTIONS}) target_link_libraries(VulkanMemoryAllocator PUBLIC Vulkan::Vulkan) endif() @@ -47,8 +35,8 @@ target_compile_definitions( VulkanMemoryAllocator PUBLIC - VMA_STATIC_VULKAN_FUNCTIONS=$ - VMA_DYNAMIC_VULKAN_FUNCTIONS=$ + VMA_STATIC_VULKAN_FUNCTIONS=$ + VMA_DYNAMIC_VULKAN_FUNCTIONS=$ VMA_DEBUG_ALWAYS_DEDICATED_MEMORY=$ VMA_DEBUG_INITIALIZE_ALLOCATIONS=$ VMA_DEBUG_GLOBAL_MUTEX=$