Workaround for ubsan_minimal dependency in the prebuilt libdexfile_external_static.a.
Test: m WITH_DEXPREOPT=false TARGET_PRODUCT=aosp_x86_64 \
WITH_DEXPREOPT_BOOT_IMG_AND_SYSTEM_SERVER_ONLY=true \
host-unit-tests
Bug: 181740144
Bug: 172480615
Change-Id: I679b6c33876c2e227d9083c107896c6913c6ca76
diff --git a/libdexfile/Android.bp b/libdexfile/Android.bp
index 5ce5a05..bf631e9 100644
--- a/libdexfile/Android.bp
+++ b/libdexfile/Android.bp
@@ -506,6 +506,16 @@
enabled: true,
},
},
+ // TODO(b/181740144): Enable a ubsan check to create a dependency on
+ // ubsan_minimal. It's needed to be able to link with the prebuilt
+ // libdexfile_external_static.a, which contains libziparchive.a, which is
+ // built with some ubsan checks
+ // (https://cs.android.com/android/platform/superproject/+/master:system/libziparchive/Android.bp;l=47-59;drc=c7b498fdf2002194709e40ea58ce39f43684fc14)
+ // that the SDK snapshots currently don't propagate properly for static
+ // libs.
+ sanitize: {
+ misc_undefined: ["shift"],
+ },
}
filegroup {