Move odex related files to product-specific dir.
For target Java libraries, now the LOCAL_BUILT_MODULE includes both javalib.jar
and the .odex file, if dexpreopt is enabled.
These 2 files are moved to a product-specific dir in this change.
For target Java Libraries, $(intermediates) now points to the product-specific dir.
There is still a javalib.jar in the $(intermediates.COMMON) dir, which is used as dependency.
Nothing is changed for host Java libraries.
Change-Id: I2546dbb940c74537864ca002d1acb49bb731fbbc
diff --git a/core/cleanbuild.mk b/core/cleanbuild.mk
index dbc64ff..cf25ce1 100644
--- a/core/cleanbuild.mk
+++ b/core/cleanbuild.mk
@@ -187,10 +187,8 @@
./$(PRODUCT_OUT)/recovery \
./$(PRODUCT_OUT)/root \
./$(PRODUCT_OUT)/system \
- ./$(PRODUCT_OUT)/dex_bootjars
-
-# TODO: move the dex-preopt files to a product-specific directory
-installclean_files += ./$(TARGET_OUT_COMMON_INTERMEDIATES)/JAVA_LIBRARIES/*/javalib.jar
+ ./$(PRODUCT_OUT)/dex_bootjars \
+ ./$(PRODUCT_OUT)/obj/JAVA_LIBRARIES
# The files/dirs to delete during a dataclean, which removes any files
# in the staging and emulator data partitions.