xref: /aosp_15_r20/external/skia/src/gpu/vk/vulkanmemoryallocator/BUILD.gn (revision c8dee2aa9b3f27cf6c858bd81872bdeb2c07ed17)
1# Copyright 2018 Google Inc.
2#
3# Use of this source code is governed by a BSD-style license that can be
4# found in the LICENSE file.
5
6import("../../../../gn/skia.gni")
7
8config("vulkanmemoryallocator_public") {
9  include_dirs = [
10    ".",
11    "$skia_vulkan_memory_allocator_dir/include",
12  ]
13}
14
15source_set("vulkanmemoryallocator") {
16  public_configs = [ ":vulkanmemoryallocator_public" ]
17
18  include_dirs = [
19    "../../../../include/third_party/vulkan",
20    "../../../../",
21  ]
22  defines = [ "SK_USE_INTERNAL_VULKAN_HEADERS" ]
23
24  if (skia_disable_vma_stl_shared_mutex) {
25    defines += [ "VMA_USE_STL_SHARED_MUTEX=0" ]
26  }
27
28  sources = [
29    "VulkanMemoryAllocatorWrapper.cpp",
30    "VulkanMemoryAllocatorWrapper.h",
31  ]
32
33  # Warnings are just noise if we're not maintaining the code.
34  if (is_win) {
35    cflags = [ "/w" ]
36  } else {
37    cflags = [ "-w" ]
38  }
39}
40