Make package functions take an argument
In preparation for rearranging the way jars and apks are built.
Relands Ib9f0da132196942062c58fd5b12e84588106724e with a fix to
correctly include classes.dex in hostdex jars.
Test: m checkbuild
Change-Id: I397544456b8ce5827716fcd1828de707b719c2bb
diff --git a/core/dpi_specific_apk.mk b/core/dpi_specific_apk.mk
index f32daf5..20bbbe2 100644
--- a/core/dpi_specific_apk.mk
+++ b/core/dpi_specific_apk.mk
@@ -51,16 +51,16 @@
@echo "target Package: $(PRIVATE_MODULE) ($@)"
$(if $(PRIVATE_SOURCE_ARCHIVE),\
$(call initialize-package-file,$(PRIVATE_SOURCE_ARCHIVE),$@),\
- $(create-empty-package))
- $(add-assets-to-package)
+ $(call create-empty-package,$@))
+ $(call add-assets-to-package,$@)
ifneq ($(jni_shared_libraries),)
- $(add-jni-shared-libs-to-package)
+ $(call add-jni-shared-libs-to-package,$@)
endif
ifeq ($(full_classes_jar),)
# We don't build jar, need to add the Java resources here.
$(if $(PRIVATE_EXTRA_JAR_ARGS),$(call add-java-resources-to,$@))
else
- $(add-dex-to-package)
+ $(call add-dex-to-package,$@)
endif
$(sign-package)