diff --git a/core/package.mk b/core/package.mk index 2012351653..36fb54c1dc 100644 --- a/core/package.mk +++ b/core/package.mk @@ -130,11 +130,13 @@ LOCAL_BUILT_MODULE_STEM := package.apk LOCAL_PROGUARD_ENABLED:=$(strip $(LOCAL_PROGUARD_ENABLED)) ifndef LOCAL_PROGUARD_ENABLED +ifneq ($(DISABLE_PROGUARD),true) ifneq ($(filter user userdebug, $(TARGET_BUILD_VARIANT)),) # turn on Proguard by default for user & userdebug build LOCAL_PROGUARD_ENABLED :=full endif endif +endif ifeq ($(LOCAL_PROGUARD_ENABLED),disabled) # the package explicitly request to disable proguard. LOCAL_PROGUARD_ENABLED :=