Convert cc to AndroidMkEntries
Use AndroidMkEntries so the next patch can use ExtraFooters, which
doesn't exist in AndroidMkData.
Bug: 149591522
the bug is not exactly related to this change, but it is the bug
that the follow-up changes are trying to fix.
Test: manually diff out/soong/Android.aosp_x86_64.mk
Merged-In: Ia3006b6747813693cf7e2b536030b21f3109f538
Change-Id: Ia3006b6747813693cf7e2b536030b21f3109f538
(cherry picked from commit d80cbca76d
)
This commit is contained in:
@@ -609,18 +609,18 @@ func (sanitize *sanitize) flags(ctx ModuleContext, flags Flags) Flags {
|
||||
return flags
|
||||
}
|
||||
|
||||
func (sanitize *sanitize) AndroidMk(ctx AndroidMkContext, ret *android.AndroidMkData) {
|
||||
func (sanitize *sanitize) AndroidMkEntries(ctx AndroidMkContext, entries *android.AndroidMkEntries) {
|
||||
// Add a suffix for cfi/hwasan/scs-enabled static/header libraries to allow surfacing
|
||||
// both the sanitized and non-sanitized variants to make without a name conflict.
|
||||
if ret.Class == "STATIC_LIBRARIES" || ret.Class == "HEADER_LIBRARIES" {
|
||||
if entries.Class == "STATIC_LIBRARIES" || entries.Class == "HEADER_LIBRARIES" {
|
||||
if Bool(sanitize.Properties.Sanitize.Cfi) {
|
||||
ret.SubName += ".cfi"
|
||||
entries.SubName += ".cfi"
|
||||
}
|
||||
if Bool(sanitize.Properties.Sanitize.Hwaddress) {
|
||||
ret.SubName += ".hwasan"
|
||||
entries.SubName += ".hwasan"
|
||||
}
|
||||
if Bool(sanitize.Properties.Sanitize.Scs) {
|
||||
ret.SubName += ".scs"
|
||||
entries.SubName += ".scs"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user