Enable linker warning toast for userdebug/eng builds
We did not want this to appear for dogfood devices before
because it was noisy, most of popular apps fixed this
problem and it should be much less noisy.
Bug: http://b/62455348
Test: make
Change-Id: Icd28e9ef87f2d1edf456d178741c67ef42670ae1
diff --git a/core/main.mk b/core/main.mk
index b50e0e7..8461e62 100644
--- a/core/main.mk
+++ b/core/main.mk
@@ -187,11 +187,16 @@
#
# -----------------------------------------------------------------
-# Enable dynamic linker developer warnings for all builds except
-# final release.
+# Enable dynamic linker developer warnings for userdebug, eng
+# and non-REL builds
+ifneq ($(TARGET_BUILD_VARIANT),user)
+ ADDITIONAL_BUILD_PROPERTIES += ro.bionic.ld.warning=1
+else
+# Enable it for user builds as long as they are not final.
ifneq ($(PLATFORM_VERSION_CODENAME),REL)
ADDITIONAL_BUILD_PROPERTIES += ro.bionic.ld.warning=1
endif
+endif
ADDITIONAL_BUILD_PROPERTIES += ro.treble.enabled=${PRODUCT_FULL_TREBLE}