am 99332f11
: Allow for opt-in of proguard shrinking of tests with new flag
* commit '99332f11c5cdf1e58eb056c019d3ca8b1e3f034a': Allow for opt-in of proguard shrinking of tests with new flag
This commit is contained in:
@@ -378,7 +378,7 @@ $(full_classes_jar): $(full_classes_emma_jar) | $(ACP)
|
|||||||
|
|
||||||
# Run proguard if necessary, otherwise just copy the file.
|
# Run proguard if necessary, otherwise just copy the file.
|
||||||
ifdef LOCAL_PROGUARD_ENABLED
|
ifdef LOCAL_PROGUARD_ENABLED
|
||||||
ifneq ($(filter-out full custom nosystem obfuscation optimization,$(LOCAL_PROGUARD_ENABLED)),)
|
ifneq ($(filter-out full custom nosystem obfuscation optimization shrinktests,$(LOCAL_PROGUARD_ENABLED)),)
|
||||||
$(warning while processing: $(LOCAL_MODULE))
|
$(warning while processing: $(LOCAL_MODULE))
|
||||||
$(error invalid value for LOCAL_PROGUARD_ENABLED: $(LOCAL_PROGUARD_ENABLED))
|
$(error invalid value for LOCAL_PROGUARD_ENABLED: $(LOCAL_PROGUARD_ENABLED))
|
||||||
endif
|
endif
|
||||||
@@ -395,6 +395,9 @@ endif
|
|||||||
# If this is a test package, add proguard keep flags for tests.
|
# If this is a test package, add proguard keep flags for tests.
|
||||||
ifneq ($(LOCAL_INSTRUMENTATION_FOR)$(filter tests,$(LOCAL_MODULE_TAGS)),)
|
ifneq ($(LOCAL_INSTRUMENTATION_FOR)$(filter tests,$(LOCAL_MODULE_TAGS)),)
|
||||||
proguard_flags += -include $(BUILD_SYSTEM)/proguard_tests.flags
|
proguard_flags += -include $(BUILD_SYSTEM)/proguard_tests.flags
|
||||||
|
ifeq ($(filter shrinktests,$(LOCAL_PROGUARD_ENABLED)),)
|
||||||
|
proguard_flags += -dontshrink # don't shrink tests by default
|
||||||
|
endif # shrinktests
|
||||||
endif # test package
|
endif # test package
|
||||||
ifeq ($(filter obfuscation,$(LOCAL_PROGUARD_ENABLED)),)
|
ifeq ($(filter obfuscation,$(LOCAL_PROGUARD_ENABLED)),)
|
||||||
# By default no obfuscation
|
# By default no obfuscation
|
||||||
|
@@ -1,5 +1,6 @@
|
|||||||
# Keep everything for tests
|
# Keep everything for tests
|
||||||
-dontshrink
|
# This flag has been moved to the makefiles and is set for tests by default.
|
||||||
|
#-dontshrink
|
||||||
|
|
||||||
# But we may want to obfuscate if the main app gets obfuscated.
|
# But we may want to obfuscate if the main app gets obfuscated.
|
||||||
# This flag has been moved to the makefiles.
|
# This flag has been moved to the makefiles.
|
||||||
|
Reference in New Issue
Block a user