Only default to vulkan loader in standalone

The default dawn_vulkan_loader_dir path is only guaranteed to exist in
standalone builds.

Should fix roll into Skia, which doesn't override dawn_vulkan_loader_dir
in its BUILD.gn files. Build fix confirmed locally. Sample roll failure:
https://skia-review.googlesource.com/c/skia/+/477896/

Bug: dawn:1191
Change-Id: Iea56475504afbe8926557371be9af5d345010b38
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/71443
Commit-Queue: Kai Ninomiya <kainino@chromium.org>
Reviewed-by: Loko Kung <lokokung@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
Kai Ninomiya 2021-12-02 01:05:41 +00:00 committed by Dawn LUCI CQ
parent 25e41622c8
commit ec5aa6e5df
1 changed files with 5 additions and 1 deletions

View File

@ -63,7 +63,11 @@ if (!defined(dawn_swiftshader_dir)) {
}
if (!defined(dawn_vulkan_loader_dir)) {
dawn_vulkan_loader_dir = "//third_party/vulkan-deps/vulkan-loader/src"
# Default to the Vulkan loader not being available except in standalone.
dawn_vulkan_loader_dir = ""
if (dawn_standalone) {
dawn_vulkan_loader_dir = "//third_party/vulkan-deps/vulkan-loader/src"
}
}
if (!defined(dawn_vulkan_validation_layers_dir)) {