Only define proguard dictionary as output if obfuscating
If we're not obfuscating, proguard doesn't generate the mapping file,
and ninja will consider the edge dirty, since one of the output files
does not exist.
Also disable it for jack, since jack writes to a different file.
Bug: 66929996
Test: m cts; m cts
Test: m ahat-test with a clean build
Change-Id: Iff6707c44cbd86cd9328bbad8322398bc9d960fd
diff --git a/core/java.mk b/core/java.mk
index ea16779..6a6fa92 100644
--- a/core/java.mk
+++ b/core/java.mk
@@ -724,7 +724,9 @@
endif
endif
-$(full_classes_proguard_jar): .KATI_IMPLICIT_OUTPUTS := $(proguard_dictionary)
+ifneq ($(filter obfuscation,$(LOCAL_PROGUARD_ENABLED)),)
+ $(full_classes_proguard_jar): .KATI_IMPLICIT_OUTPUTS := $(proguard_dictionary)
+endif
$(full_classes_proguard_jar): PRIVATE_PROGUARD_INJAR_FILTERS := $(proguard_injar_filters)
$(full_classes_proguard_jar): PRIVATE_EXTRA_INPUT_JAR := $(extra_input_jar)
$(full_classes_proguard_jar): PRIVATE_PROGUARD_FLAGS := $(legacy_proguard_flags) $(common_proguard_flags) $(LOCAL_PROGUARD_FLAGS)