Skip apex dep check when sanitizer diag is enabled
To avoid adding ubsan to the apex allowed_dep list, this commit adds a
check on depedency tags to see if apex check should be skipped.
The check is only used on sharedLib dependencies when diag mode are enabled
for sanitizers.
Bug: 158010610
Test: make build for aosp-sargo and aosp_cf_x86_phone-userdebug
Change-Id: I3d7dbb70d8c80ffae1854819cf8cf9e6b0b15c00
diff --git a/android/apex.go b/android/apex.go
index f6eca86..47d14cc 100644
--- a/android/apex.go
+++ b/android/apex.go
@@ -253,6 +253,12 @@
CopyDirectlyInAnyApex()
}
+// Interface that identifies dependencies to skip Apex dependency check
+type SkipApexAllowedDependenciesCheck interface {
+ // Returns true to skip the Apex dependency check, which limits the allowed dependency in build.
+ SkipApexAllowedDependenciesCheck() bool
+}
+
// ApexModuleBase provides the default implementation for the ApexModule interface. APEX-aware
// modules are expected to include this struct and call InitApexModule().
type ApexModuleBase struct {