Allow cfi enabled modules in mixed build.
Bug: None
Test: Locally tested
Change-Id: I53c4ad8428cf05ceee3d73b4f97c2b9db2285c38
diff --git a/cc/cc.go b/cc/cc.go
index c9f00e2..bafd625 100644
--- a/cc/cc.go
+++ b/cc/cc.go
@@ -1916,7 +1916,6 @@
unsupportedSanitizers := []*bool{
sanitizeProps.Safestack,
- sanitizeProps.Cfi,
sanitizeProps.Scudo,
BoolPtr(len(c.sanitize.Properties.Sanitize.Recover) > 0),
BoolPtr(c.sanitize.Properties.Sanitize.Blocklist != nil),
@@ -1935,6 +1934,8 @@
if ubsanEnabled && !c.MinimalRuntimeNeeded() {
return false
}
+ } else if san == cfi {
+ continue
} else if c.sanitize.isSanitizerEnabled(san) {
return false
}
diff --git a/cc/cc_test.go b/cc/cc_test.go
index 173911b..701c3bb 100644
--- a/cc/cc_test.go
+++ b/cc/cc_test.go
@@ -5538,7 +5538,7 @@
name: "foo_cfi",
variant: "android_arm64_armv8-a_static_cfi_apex28",
expectedOutputPaths: []string{
- "out/soong/.intermediates/foo_cfi/android_arm64_armv8-a_static_cfi_apex28/foo_cfi.a",
+ "outputbase/execroot/__main__/foo_cfi.a",
},
},
{