Adding support for building AFLpp
Test: Build AFL fuzzers locally and ran them Change-Id: Ie4fbd258c87663cf81d7d64d575b3da1d5febc17
This commit is contained in:
11
cc/cc.go
11
cc/cc.go
@@ -61,6 +61,9 @@ func RegisterCCBuildComponents(ctx android.RegistrationContext) {
|
||||
ctx.TopDown("sanitize_runtime_deps", sanitizerRuntimeDepsMutator).Parallel()
|
||||
ctx.BottomUp("sanitize_runtime", sanitizerRuntimeMutator).Parallel()
|
||||
|
||||
ctx.TopDown("fuzz_deps", fuzzMutatorDeps)
|
||||
ctx.BottomUp("fuzz", fuzzMutator)
|
||||
|
||||
ctx.BottomUp("coverage", coverageMutator).Parallel()
|
||||
|
||||
ctx.TopDown("afdo_deps", afdoDepsMutator)
|
||||
@@ -838,6 +841,7 @@ type Module struct {
|
||||
stl *stl
|
||||
sanitize *sanitize
|
||||
coverage *coverage
|
||||
fuzzer *fuzzer
|
||||
sabi *sabi
|
||||
vndkdep *vndkdep
|
||||
lto *lto
|
||||
@@ -1163,6 +1167,9 @@ func (c *Module) Init() android.Module {
|
||||
if c.coverage != nil {
|
||||
c.AddProperties(c.coverage.props()...)
|
||||
}
|
||||
if c.fuzzer != nil {
|
||||
c.AddProperties(c.fuzzer.props()...)
|
||||
}
|
||||
if c.sabi != nil {
|
||||
c.AddProperties(c.sabi.props()...)
|
||||
}
|
||||
@@ -1680,6 +1687,7 @@ func newModule(hod android.HostOrDeviceSupported, multilib android.Multilib) *Mo
|
||||
module.stl = &stl{}
|
||||
module.sanitize = &sanitize{}
|
||||
module.coverage = &coverage{}
|
||||
module.fuzzer = &fuzzer{}
|
||||
module.sabi = &sabi{}
|
||||
module.vndkdep = &vndkdep{}
|
||||
module.lto = <o{}
|
||||
@@ -1901,6 +1909,9 @@ func (c *Module) GenerateAndroidBuildActions(actx android.ModuleContext) {
|
||||
if c.coverage != nil {
|
||||
flags, deps = c.coverage.flags(ctx, flags, deps)
|
||||
}
|
||||
if c.fuzzer != nil {
|
||||
flags = c.fuzzer.flags(ctx, flags)
|
||||
}
|
||||
if c.lto != nil {
|
||||
flags = c.lto.flags(ctx, flags)
|
||||
}
|
||||
|
Reference in New Issue
Block a user