diff --git a/core/config.mk b/core/config.mk index 0cf12937b..503be2f70 100644 --- a/core/config.mk +++ b/core/config.mk @@ -497,6 +497,8 @@ MAINDEXCLASSES := $(HOST_OUT_EXECUTABLES)/mainDexClasses SOONG_ZIP := $(SOONG_HOST_OUT_EXECUTABLES)/soong_zip ZIP2ZIP := $(SOONG_HOST_OUT_EXECUTABLES)/zip2zip +JAVAC_FILTER := $(SOONG_HOST_OUT_EXECUTABLES)/soong_javac_filter + # Always use prebuilts for ckati and makeparallel prebuilt_build_tools := prebuilts/build-tools ifeq ($(filter address,$(SANITIZE_HOST)),) diff --git a/core/definitions.mk b/core/definitions.mk index 71b80e0d3..e9ec26a23 100644 --- a/core/definitions.mk +++ b/core/definitions.mk @@ -2236,7 +2236,7 @@ $(if $(PRIVATE_HAS_RS_SOURCES), \ $(hide) tr ' ' '\n' < $(PRIVATE_CLASS_INTERMEDIATES_DIR)/java-source-list \ | $(NORMALIZE_PATH) | sort -u > $(PRIVATE_CLASS_INTERMEDIATES_DIR)/java-source-list-uniq $(hide) if [ -s $(PRIVATE_CLASS_INTERMEDIATES_DIR)/java-source-list-uniq ] ; then \ - $(1) -encoding UTF-8 \ + ( $(1) -encoding UTF-8 \ $(if $(findstring true,$(PRIVATE_WARNINGS_ENABLE)),$(xlint_unchecked),) \ $(2) \ $(addprefix -classpath ,$(strip \ @@ -2245,7 +2245,7 @@ $(hide) if [ -s $(PRIVATE_CLASS_INTERMEDIATES_DIR)/java-source-list-uniq ] ; the -extdirs "" -d $(PRIVATE_CLASS_INTERMEDIATES_DIR) \ $(PRIVATE_JAVACFLAGS) \ \@$(PRIVATE_CLASS_INTERMEDIATES_DIR)/java-source-list-uniq \ - || ( rm -rf $(PRIVATE_CLASS_INTERMEDIATES_DIR) ; exit 41 ) \ + || ( rm -rf $(PRIVATE_CLASS_INTERMEDIATES_DIR) ; exit 41 ) ) 2>&1 | $(JAVAC_FILTER); \ fi $(if $(PRIVATE_JAVA_LAYERS_FILE), $(hide) build/tools/java-layers.py \ $(PRIVATE_JAVA_LAYERS_FILE) \@$(PRIVATE_CLASS_INTERMEDIATES_DIR)/java-source-list-uniq,) diff --git a/core/host_dalvik_java_library.mk b/core/host_dalvik_java_library.mk index 0e358447f..503f67bdf 100644 --- a/core/host_dalvik_java_library.mk +++ b/core/host_dalvik_java_library.mk @@ -90,6 +90,8 @@ $(full_classes_compiled_jar): \ $(full_java_lib_deps) \ $(jar_manifest_file) \ $(proto_java_sources_file_stamp) \ + $(NORMALIZE_PATH) \ + $(JAVAC_FILTER) \ $(LOCAL_ADDITIONAL_DEPENDENCIES) $(transform-host-java-to-package) diff --git a/core/host_java_library.mk b/core/host_java_library.mk index cc26d7cc9..ba2999f07 100644 --- a/core/host_java_library.mk +++ b/core/host_java_library.mk @@ -69,6 +69,7 @@ $(full_classes_compiled_jar): \ $(jar_manifest_file) \ $(proto_java_sources_file_stamp) \ $(NORMALIZE_PATH) \ + $(JAVAC_FILTER) \ $(LOCAL_ADDITIONAL_DEPENDENCIES) $(transform-host-java-to-package) diff --git a/core/java.mk b/core/java.mk index 4e5432fe1..d1ac6c7cc 100644 --- a/core/java.mk +++ b/core/java.mk @@ -446,6 +446,7 @@ $(full_classes_compiled_jar): \ $(RenderScript_file_stamp) \ $(proto_java_sources_file_stamp) \ $(NORMALIZE_PATH) \ + $(JAVAC_FILTER) \ $(LOCAL_ADDITIONAL_DEPENDENCIES) $(transform-java-to-classes.jar)