From 8c66e7aa7abefc3222046d5c4169c669b31355a4 Mon Sep 17 00:00:00 2001 From: Attila Uygun Date: Tue, 12 Sep 2023 19:57:11 +0200 Subject: [PATCH] Move VMA_STATIC_VULKAN_FUNCTIONS to vma/BUILD.gn --- src/third_party/vma/BUILD.gn | 5 ++++- src/third_party/vulkan/BUILD.gn | 9 +++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/third_party/vma/BUILD.gn b/src/third_party/vma/BUILD.gn index b73e3eb..4fad35d 100644 --- a/src/third_party/vma/BUILD.gn +++ b/src/third_party/vma/BUILD.gn @@ -1,10 +1,13 @@ source_set("vma") { configs -= [ "//build:warnings" ] + defines = [ "VMA_STATIC_VULKAN_FUNCTIONS=1" ] + cflags = [ "-Wno-nullability-completeness" ] + sources = [ "vk_mem_alloc.cpp", "vk_mem_alloc.h", ] - deps = [ "//src/third_party/vulkan" ] + deps = [] } diff --git a/src/third_party/vulkan/BUILD.gn b/src/third_party/vulkan/BUILD.gn index 7c0ae0e..b9e21da 100644 --- a/src/third_party/vulkan/BUILD.gn +++ b/src/third_party/vulkan/BUILD.gn @@ -1,15 +1,12 @@ config("vulkan_public") { include_dirs = [ "include" ] - defines = [ "VMA_STATIC_VULKAN_FUNCTIONS=1" ] - cflags = [] if (target_os == "linux") { - defines += [ "VK_USE_PLATFORM_XLIB_KHR" ] + defines = [ "VK_USE_PLATFORM_XLIB_KHR" ] } else if (target_os == "win") { - defines += [ "VK_USE_PLATFORM_WIN32_KHR" ] + defines = [ "VK_USE_PLATFORM_WIN32_KHR" ] } else if (target_os == "android") { - defines += [ "VK_USE_PLATFORM_ANDROID_KHR" ] - cflags += [ "-Wno-nullability-completeness" ] + defines = [ "VK_USE_PLATFORM_ANDROID_KHR" ] } }