Merge "Allow building framework.jar and framework-res.apk" am: 85c87cef01
am: 2fc6f692d1
am: 5f3053a307
Change-Id: Id93733384a0c3636098d457bc22a474da67561d1
This commit is contained in:
12
java/java.go
12
java/java.go
@@ -41,7 +41,6 @@ func init() {
|
||||
android.RegisterModuleType("java_binary_host", BinaryHostFactory)
|
||||
android.RegisterModuleType("java_import", ImportFactory)
|
||||
android.RegisterModuleType("java_import_host", ImportFactoryHost)
|
||||
android.RegisterModuleType("android_app", AndroidAppFactory)
|
||||
|
||||
android.RegisterSingletonType("logtags", LogtagsSingleton)
|
||||
}
|
||||
@@ -206,6 +205,10 @@ type Module struct {
|
||||
|
||||
// installed file for binary dependency
|
||||
installFile android.Path
|
||||
|
||||
// list of .java files and srcjars that was passed to javac
|
||||
compiledJavaSrcs android.Paths
|
||||
compiledSrcJars android.Paths
|
||||
}
|
||||
|
||||
type Dependency interface {
|
||||
@@ -355,6 +358,9 @@ func (j *Module) deps(ctx android.BottomUpMutatorContext) {
|
||||
} else if *j.deviceProperties.System_modules != "none" && ctx.Config().TargetOpenJDK9() {
|
||||
ctx.AddDependency(ctx.Module(), systemModulesTag, *j.deviceProperties.System_modules)
|
||||
}
|
||||
if ctx.ModuleName() == "framework" {
|
||||
ctx.AddDependency(ctx.Module(), frameworkResTag, "framework-res")
|
||||
}
|
||||
}
|
||||
|
||||
ctx.AddDependency(ctx.Module(), libTag, j.properties.Libs...)
|
||||
@@ -618,6 +624,10 @@ func (j *Module) compile(ctx android.ModuleContext, extraSrcJars ...android.Path
|
||||
}
|
||||
}
|
||||
|
||||
// Store the list of .java files that was passed to javac
|
||||
j.compiledJavaSrcs = uniqueSrcFiles
|
||||
j.compiledSrcJars = srcJars
|
||||
|
||||
enable_sharding := false
|
||||
if ctx.Device() && !ctx.Config().IsEnvFalse("TURBINE_ENABLED") {
|
||||
if j.properties.Javac_shard_size != nil && *(j.properties.Javac_shard_size) > 0 {
|
||||
|
Reference in New Issue
Block a user