Commit 82c9e196 authored by Alexis Hetu's avatar Alexis Hetu Committed by Chromium LUCI CQ

Make sure ANGLE can find the proper libraries

This cl is in the context of replacing SwiftShader's GL libraries
with SwANGLE (ANGLE with SwiftShader Vulkan as its backend). In order
to allow ANGLE to find the proper libvulkan.so when executing tests
on the bots, we have to make sure the proper rpath is set.

The affected tests include:
app_shell_unittests, aura_unittests, cc_unittests,
compositor_unittests, gpu_unittests, interactive_ui_tests
message_center_unittests, media_unittests, snapshot_unittests
unit_tests, views_unittests, viz_unittests, wm_unittests

A CFI suppression has also been added for expected behavior of
the vulkan loader triggering a CFI error when calling functions
from the system libvulkan library.

TBR_REASON: BUILD.gn changes identical to those already approved in https://chromium-review.googlesource.com/c/chromium/src/+/2565490

TBR: kbr@chromium.org
Bug: chromium:1060139
Change-Id: Ib2e15ae61e11b5a3b37cf65552f579faf287f809
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2575112
Commit-Queue: Alexis Hétu <sugoi@chromium.org>
Reviewed-by: default avatarKenneth Russell <kbr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#834139}
parent 9aec30c4
......@@ -387,6 +387,7 @@ static_library("test_support") {
"//third_party/blink/public:blink",
"//third_party/blink/public:test_support",
"//third_party/blink/public/strings:strings_grit",
"//ui/gl:test_support",
]
deps = [
......@@ -459,7 +460,6 @@ static_library("test_support") {
"//ui/events/blink",
"//ui/gfx:test_support",
"//ui/gl",
"//ui/gl:test_support",
"//ui/native_theme",
"//ui/resources",
"//ui/shell_dialogs:shell_dialogs",
......
......@@ -169,6 +169,7 @@ src:*ui/gl/gl_bindings_autogen_*
# Calls to vulkan function pointers from shared library.
src:*third_party/vulkan_memory_allocator/src/vk_mem_alloc.h
src:*third_party/angle/third_party/vulkan-loader/src/loader*
src:*components/os_crypt/*
......
......@@ -512,6 +512,15 @@ static_library("test_support") {
if (use_ozone) {
deps += [ "//ui/ozone" ]
}
public_configs = []
# If the run-time search path isn't set properly when we use ANGLE with its
# Vulkan backend, it may end up finding the system libvulkan.so rather than
# the one built in the output directory
if ((is_linux || is_chromeos) && !is_component_build) {
public_configs += [ "//build/config/gcc:rpath_for_built_shared_libraries" ]
}
}
source_set("run_all_unittests") {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment