Lines Matching refs:ctx
84 func expandTopHalf(ctx android.ModuleContext) android.OptionalPath {
86 ctx.VisitDirectDeps(func(dep android.Module) {
87 depTag := ctx.OtherModuleDependencyTag(dep)
96 func expandSeSources(ctx android.ModuleContext, srcFiles []string) android.Paths {
100 module := ctx.GetDirectDepWithTag(m, android.SourceDepTag)
106 if ctx.ProductSpecific() {
108 } else if ctx.SystemExtSpecific() {
114 ctx.ModuleErrorf("srcs dependency %q is not an selinux filegroup", m)
117 p := android.PathForModuleSrc(ctx, s)
124 func (c *cilCompatMap) GenerateAndroidBuildActions(ctx android.ModuleContext) {
125 c.installPath = android.PathForModuleInstall(ctx, "etc", "selinux", "mapping")
127 srcFiles := expandSeSources(ctx, c.properties.Bottom_half)
131 ctx.PropertyErrorf("bottom_half", "%s has to be a .cil file.", src.String())
135 bottomHalf := android.PathForModuleGen(ctx, "bottom_half")
136 ctx.Build(pctx, android.BuildParams{
142 topHalf := expandTopHalf(ctx)
144 out := android.PathForModuleGen(ctx, c.Name())
145 ctx.ModuleBuild(pctx, android.ModuleBuildParams{
163 func (c *cilCompatMap) DepsMutator(ctx android.BottomUpMutatorContext) {
164 android.ExtractSourcesDeps(ctx, c.properties.Bottom_half)
166 ctx.AddDependency(c, TopHalfDepTag, String(c.properties.Top_half))