From dd88248732202c745576bc13634f31b0a98dbdb2 Mon Sep 17 00:00:00 2001 From: Siarhei Vishniakou Date: Fri, 28 Apr 2023 21:13:26 +0000 Subject: Add sanitizers to libinput The library was already getting sanitized for some undefined behaviour on device. This change will move the sanitization to all platforms like host, and also expands the list of sanitizers. We can't enable the address sanitizer today, unfortunately. It causes the libinput to not be able to load on some configurations. It's not clear what's causing that yet. Bug: 271455682 Test: presubmit (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:9a580625a8bd7631cdffae81ab68e5fd4e7bc1be) Merged-In: I9588b0f7b42eec2070cd5556f94671fd934b7bec Change-Id: I9588b0f7b42eec2070cd5556f94671fd934b7bec --- libs/input/Android.bp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/libs/input/Android.bp b/libs/input/Android.bp index 869458c407..4be7328346 100644 --- a/libs/input/Android.bp +++ b/libs/input/Android.bp @@ -85,6 +85,12 @@ cc_library { "-Wl,--exclude-libs=libtflite_static.a", ], + sanitize: { + undefined: true, + all_undefined: true, + misc_undefined: ["integer"], + }, + static_libs: [ "libui-types", "libtflite_static", @@ -117,10 +123,6 @@ cc_library { "libgui_window_info_static", ], - sanitize: { - misc_undefined: ["integer"], - }, - required: [ "motion_predictor_model_prebuilt", ], -- cgit v1.2.3-59-g8ed1b