Merge "AIDEGen: Remove the duplicate *.srcjar from srcs"
This commit is contained in:
commit
d90d208628
13
java/java.go
13
java/java.go
|
@ -348,8 +348,8 @@ type Module struct {
|
||||||
// list of SDK lib names that this java moudule is exporting
|
// list of SDK lib names that this java moudule is exporting
|
||||||
exportedSdkLibs []string
|
exportedSdkLibs []string
|
||||||
|
|
||||||
// list of source files, collected from compiledJavaSrcs and compiledSrcJars
|
// list of source files, collected from srcFiles with uniqie java and all kt files,
|
||||||
// filter out Exclude_srcs, will be used by android.IDEInfo struct
|
// will be used by android.IDEInfo struct
|
||||||
expandIDEInfoCompiledSrcs []string
|
expandIDEInfoCompiledSrcs []string
|
||||||
|
|
||||||
// expanded Jarjar_rules
|
// expanded Jarjar_rules
|
||||||
|
@ -1037,9 +1037,6 @@ func (j *Module) compile(ctx android.ModuleContext, aaptSrcJar android.Path) {
|
||||||
srcJars = append(srcJars, aaptSrcJar)
|
srcJars = append(srcJars, aaptSrcJar)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Collect source files and filter out Exclude_srcs that IDEInfo struct will use
|
|
||||||
j.expandIDEInfoCompiledSrcs = append(j.expandIDEInfoCompiledSrcs, srcFiles.Strings()...)
|
|
||||||
|
|
||||||
if j.properties.Jarjar_rules != nil {
|
if j.properties.Jarjar_rules != nil {
|
||||||
j.expandJarjarRules = android.PathForModuleSrc(ctx, *j.properties.Jarjar_rules)
|
j.expandJarjarRules = android.PathForModuleSrc(ctx, *j.properties.Jarjar_rules)
|
||||||
}
|
}
|
||||||
|
@ -1056,6 +1053,9 @@ func (j *Module) compile(ctx android.ModuleContext, aaptSrcJar android.Path) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Collect .java files for AIDEGen
|
||||||
|
j.expandIDEInfoCompiledSrcs = append(j.expandIDEInfoCompiledSrcs, uniqueSrcFiles.Strings()...)
|
||||||
|
|
||||||
var kotlinJars android.Paths
|
var kotlinJars android.Paths
|
||||||
|
|
||||||
if srcFiles.HasExt(".kt") {
|
if srcFiles.HasExt(".kt") {
|
||||||
|
@ -1080,6 +1080,9 @@ func (j *Module) compile(ctx android.ModuleContext, aaptSrcJar android.Path) {
|
||||||
kotlinSrcFiles = append(kotlinSrcFiles, uniqueSrcFiles...)
|
kotlinSrcFiles = append(kotlinSrcFiles, uniqueSrcFiles...)
|
||||||
kotlinSrcFiles = append(kotlinSrcFiles, srcFiles.FilterByExt(".kt")...)
|
kotlinSrcFiles = append(kotlinSrcFiles, srcFiles.FilterByExt(".kt")...)
|
||||||
|
|
||||||
|
// Collect .kt files for AIDEGen
|
||||||
|
j.expandIDEInfoCompiledSrcs = append(j.expandIDEInfoCompiledSrcs, srcFiles.FilterByExt(".kt").Strings()...)
|
||||||
|
|
||||||
flags.classpath = append(flags.classpath, deps.kotlinStdlib...)
|
flags.classpath = append(flags.classpath, deps.kotlinStdlib...)
|
||||||
flags.classpath = append(flags.classpath, deps.kotlinAnnotations...)
|
flags.classpath = append(flags.classpath, deps.kotlinAnnotations...)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue