Merge "Filter and colorize javac output V3"
diff --git a/core/config.mk b/core/config.mk
index f033ad9..884be1e 100644
--- a/core/config.mk
+++ b/core/config.mk
@@ -499,6 +499,8 @@
ZIP2ZIP := $(SOONG_HOST_OUT_EXECUTABLES)/zip2zip
FILESLIST := $(SOONG_HOST_OUT_EXECUTABLES)/fileslist
+SOONG_JAVAC_WRAPPER := $(SOONG_HOST_OUT_EXECUTABLES)/soong_javac_wrapper
+
# 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 e6f4b00..72c27af 100644
--- a/core/definitions.mk
+++ b/core/definitions.mk
@@ -2206,7 +2206,7 @@
$(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 \
+ $(SOONG_JAVAC_WRAPPER) $(1) -encoding UTF-8 \
$(if $(findstring true,$(PRIVATE_WARNINGS_ENABLE)),$(xlint_unchecked),) \
$(2) \
$(addprefix -classpath ,$(strip \
diff --git a/core/host_dalvik_java_library.mk b/core/host_dalvik_java_library.mk
index a7c1ad6..7101229 100644
--- a/core/host_dalvik_java_library.mk
+++ b/core/host_dalvik_java_library.mk
@@ -97,7 +97,9 @@
$(jar_manifest_file) \
$(proto_java_sources_file_stamp) \
$(annotation_processor_deps) \
- $(LOCAL_ADDITIONAL_DEPENDENCIES)
+ $(NORMALIZE_PATH) \
+ $(LOCAL_ADDITIONAL_DEPENDENCIES) \
+ | $(SOONG_JAVAC_WRAPPER)
$(transform-host-java-to-package)
my_desugaring :=
diff --git a/core/host_java_library.mk b/core/host_java_library.mk
index 9f640b0..35dece4 100644
--- a/core/host_java_library.mk
+++ b/core/host_java_library.mk
@@ -76,7 +76,8 @@
$(proto_java_sources_file_stamp) \
$(annotation_processor_deps) \
$(NORMALIZE_PATH) \
- $(LOCAL_ADDITIONAL_DEPENDENCIES)
+ $(LOCAL_ADDITIONAL_DEPENDENCIES) \
+ | $(SOONG_JAVAC_WRAPPER)
$(transform-host-java-to-package)
javac-check : $(full_classes_compiled_jar)
diff --git a/core/java.mk b/core/java.mk
index b9c48c6..78c8ba3 100644
--- a/core/java.mk
+++ b/core/java.mk
@@ -439,7 +439,8 @@
$(proto_java_sources_file_stamp) \
$(annotation_processor_deps) \
$(NORMALIZE_PATH) \
- $(LOCAL_ADDITIONAL_DEPENDENCIES)
+ $(LOCAL_ADDITIONAL_DEPENDENCIES) \
+ | $(SOONG_JAVAC_WRAPPER)
$(transform-java-to-classes.jar)
javac-check : $(full_classes_compiled_jar)