Extract jar files to different directory than compiling

Now that we use extractPrebuilts to extract compiled classes from
jars after jarjar, it needs to extract to a different directory
than used when compiling.  Extract them to extracted/classes.  Also
move the classes.list and resources.list file out of the classes
directory so they don't find themselves and end up in downstream
jars.

Change-Id: I070323466858edc7e33e14207c98f77d540882f3
This commit is contained in:
Colin Cross
2015-04-24 15:21:41 -07:00
parent 957cc4e20d
commit 11f5654ba6

View File

@@ -234,9 +234,10 @@ func TransformJarJar(ctx common.AndroidModuleContext, classesJar string, rulesFi
func TransformPrebuiltJarToClasses(ctx common.AndroidModuleContext,
prebuilt string) (classJarSpec, resourceJarSpec jarSpec) {
classDir := filepath.Join(common.ModuleOutDir(ctx), "classes")
classFileList := filepath.Join(classDir, "classes.list")
resourceFileList := filepath.Join(classDir, "resources.list")
extractedDir := filepath.Join(common.ModuleOutDir(ctx), "extracted")
classDir := filepath.Join(extractedDir, "classes")
classFileList := filepath.Join(extractedDir, "classes.list")
resourceFileList := filepath.Join(extractedDir, "resources.list")
ctx.Build(pctx, blueprint.BuildParams{
Rule: extractPrebuilt,