Use PIE when compiling tests on Linux.

This is an attempt to make linux_msan bot less flaky which is suggested by the error message:
FATAL: Make sure to compile with -fPIE and to link with -pie.

Bug: None
Change-Id: I43f4e5c10d9a4c42a8ef5a67bf77806f0c09bf98
Reviewed-on: https://chromium-review.googlesource.com/c/libyuv/libyuv/+/6111093
Reviewed-by: Mirko Bonadei <mbonadei@chromium.org>
Commit-Queue: Jeremy Leconte <jleconte@google.com>
This commit is contained in:
Jeremy Leconte 2024-12-19 18:00:14 +01:00 committed by libyuv LUCI CQ
parent f54aac5279
commit 533dc5866b

View File

@ -395,6 +395,8 @@ if (libyuv_include_tests) {
if (is_linux || is_chromeos) {
cflags = [ "-fexceptions" ]
# For enabling ASLR.
ldflags = [ "-pie" ]
}
if (is_ios) {
configs -= [ "//build/config/compiler:default_symbols" ]