Refactor cc compiling to shared ccBase and ccDynamic initialization
Refactor common code out of NewCC* to initialize the ccBase, ccDynamic, and ccLibrary structures. Also adds an enum for the default multilib values. Change-Id: Iaeffe86bf2568b6054be4ddcee725818af45e14f
This commit is contained in:
@@ -293,12 +293,12 @@ func ArchMutator(mctx blueprint.EarlyMutatorContext) {
|
||||
}
|
||||
}
|
||||
|
||||
func InitArchModule(m AndroidModule, defaultMultilib string,
|
||||
func InitArchModule(m AndroidModule, defaultMultilib Multilib,
|
||||
propertyStructs ...interface{}) (blueprint.Module, []interface{}) {
|
||||
|
||||
base := m.base()
|
||||
|
||||
base.commonProperties.Compile_multilib = defaultMultilib
|
||||
base.commonProperties.Compile_multilib = string(defaultMultilib)
|
||||
|
||||
base.generalProperties = append(base.generalProperties,
|
||||
&base.commonProperties)
|
||||
|
@@ -80,7 +80,14 @@ type hostAndDeviceProperties struct {
|
||||
Device_supported bool
|
||||
}
|
||||
|
||||
func InitAndroidModule(m AndroidModule, hod HostOrDeviceSupported, defaultMultilib string,
|
||||
type Multilib string
|
||||
|
||||
const (
|
||||
MultilibBoth Multilib = "both"
|
||||
MultilibFirst Multilib = "first"
|
||||
)
|
||||
|
||||
func InitAndroidModule(m AndroidModule, hod HostOrDeviceSupported, defaultMultilib Multilib,
|
||||
propertyStructs ...interface{}) (blueprint.Module, []interface{}) {
|
||||
|
||||
base := m.base()
|
||||
|
Reference in New Issue
Block a user