Lines Matching refs:m

258 func (m *Module) ImageMutatorBegin(mctx android.BaseModuleContext) {
259 m.CheckVndkProperties(mctx)
260 MutateImage(mctx, m)
265 func (m *Module) CheckVndkProperties(mctx android.BaseModuleContext) {
269 if vndkdep := m.vndkdep; vndkdep != nil {
275 } else if Bool(m.VendorProperties.Vendor_available) {
278 } else if Bool(m.VendorProperties.Product_available) {
286 m.getVndkExtendsModuleName())
288 if !Bool(m.VendorProperties.Vendor_available) {
292 if Bool(m.VendorProperties.Product_available) {
296 if !m.compareVendorAndProductProps() {
309 m.getVndkExtendsModuleName())
315 func (m *Module) VendorAvailable() bool {
316 return Bool(m.VendorProperties.Vendor_available)
319 func (m *Module) OdmAvailable() bool {
320 return Bool(m.VendorProperties.Odm_available)
323 func (m *Module) ProductAvailable() bool {
324 return Bool(m.VendorProperties.Product_available)
327 func (m *Module) RamdiskAvailable() bool {
328 return Bool(m.Properties.Ramdisk_available)
331 func (m *Module) VendorRamdiskAvailable() bool {
332 return Bool(m.Properties.Vendor_ramdisk_available)
335 func (m *Module) AndroidModuleBase() *android.ModuleBase {
336 return &m.ModuleBase
339 func (m *Module) RecoveryAvailable() bool {
340 return Bool(m.Properties.Recovery_available)
343 func (m *Module) ExtraVariants() []string {
344 return m.Properties.ExtraVariants
347 func (m *Module) AppendExtraVariant(extraVariant string) {
348 m.Properties.ExtraVariants = append(m.Properties.ExtraVariants, extraVariant)
351 func (m *Module) SetRamdiskVariantNeeded(b bool) {
352 m.Properties.RamdiskVariantNeeded = b
355 func (m *Module) SetVendorRamdiskVariantNeeded(b bool) {
356 m.Properties.VendorRamdiskVariantNeeded = b
359 func (m *Module) SetRecoveryVariantNeeded(b bool) {
360 m.Properties.RecoveryVariantNeeded = b
363 func (m *Module) SetCoreVariantNeeded(b bool) {
364 m.Properties.CoreVariantNeeded = b
367 func (m *Module) SnapshotVersion(mctx android.BaseModuleContext) string {
368 if snapshot, ok := m.linker.(snapshotInterface); ok {
377 func (m *Module) KernelHeadersDecorator() bool {
378 if _, ok := m.linker.(*kernelHeadersDecorator); ok {
385 func MutateImage(mctx android.BaseModuleContext, m ImageMutatableModule) {
390 if m.VendorAvailable() {
395 if m.OdmAvailable() {
401 if m.OdmAvailable() {
408 if m.ProductAvailable() {
450 if m.NeedsLlndkVariants() {
467 } else if m.NeedsVendorPublicLibraryVariants() {
482 } else if m.IsSnapshotPrebuilt() {
485 if m.InstallInRecovery() {
488 vendorVariants = append(vendorVariants, m.SnapshotVersion(mctx))
490 } else if m.HasNonSystemVariants() && !m.IsVndkExt() {
498 if m.HasVendorVariant() {
507 if m.HasProductVariant() {
510 if !m.IsVndk() {
514 } else if vendorSpecific && m.SdkVersion() == "" {
523 if m.KernelHeadersDecorator() {
541 if coreVariantNeeded && productSpecific && m.SdkVersion() == "" {
553 if m.RamdiskAvailable() {
557 if m.AndroidModuleBase().InstallInRamdisk() {
562 if m.VendorRamdiskAvailable() {
566 if m.AndroidModuleBase().InstallInVendorRamdisk() {
571 if m.RecoveryAvailable() {
575 if m.AndroidModuleBase().InstallInRecovery() {
582 if m.KernelHeadersDecorator() &&
583 !m.IsSnapshotPrebuilt() &&
590 m.AppendExtraVariant(VendorVariationPrefix + variant)
594 m.AppendExtraVariant(ProductVariationPrefix + variant)
597 m.SetRamdiskVariantNeeded(ramdiskVariantNeeded)
598 m.SetVendorRamdiskVariantNeeded(vendorRamdiskVariantNeeded)
599 m.SetRecoveryVariantNeeded(recoveryVariantNeeded)
600 m.SetCoreVariantNeeded(coreVariantNeeded)
606 len(m.ExtraVariants()) == 0 {
607 m.Disable()
635 func squashVendorSrcs(m *Module) {
636 if lib, ok := m.compiler.(*libraryDecorator); ok {
648 func squashProductSrcs(m *Module) {
649 if lib, ok := m.compiler.(*libraryDecorator); ok {
661 func squashRecoverySrcs(m *Module) {
662 if lib, ok := m.compiler.(*libraryDecorator); ok {
674 func squashVendorRamdiskSrcs(m *Module) {
675 if lib, ok := m.compiler.(*libraryDecorator); ok {
681 m := module.(*Module)
683 m.MakeAsPlatform()
685 m.MakeAsPlatform()
686 squashVendorRamdiskSrcs(m)
688 m.MakeAsPlatform()
689 squashRecoverySrcs(m)
691 m.Properties.ImageVariationPrefix = VendorVariationPrefix
692 m.Properties.VndkVersion = strings.TrimPrefix(variant, VendorVariationPrefix)
693 squashVendorSrcs(m)
698 if vndkVersion != "current" && vndkVersion != "" && vndkVersion != m.Properties.VndkVersion {
699 m.Properties.HideFromMake = true
700 m.HideFromMake()
703 m.Properties.ImageVariationPrefix = ProductVariationPrefix
704 m.Properties.VndkVersion = strings.TrimPrefix(variant, ProductVariationPrefix)
705 squashProductSrcs(m)