policy-hal: squash multiple changes/fixes to custom policy

This commit is a squash of below changes. Only relevant
changes have been ported and the other required changes
are in base policy manager.

audiopolicy: support extended feature in audiopolicymanager
Change-Id: I1925339b591cd29f11a71c287a2e53c0627e9e62

audiopolicy: additional change for extended feature
Change-Id: I9bad6a294ddd7aee72f6f6a314666b892b730c8e

audiopolicy: Do not route audio to HDMI if HDMI not connected
Change-Id: I1c76ba3c3a1438463461ea7c41799633bd977283

audiopolicy: Fix for device selection during concurrent audio playback
Change-Id: Ibf3c1bfd05b68d70c6cb9e8b9b95e989f27c2e75

Change-Id: I00470a057cdeefff7bba3bffd333fb556f3d97e6
diff --git a/policy_hal/Android.mk b/policy_hal/Android.mk
index 874b3dd..58f73d3 100644
--- a/policy_hal/Android.mk
+++ b/policy_hal/Android.mk
@@ -27,6 +27,18 @@
 LOCAL_STATIC_LIBRARIES := \
     libmedia_helper \
 
+ifeq ($(strip $(AUDIO_FEATURE_ENABLED_EXTN_FORMATS)),true)
+LOCAL_CFLAGS += -DAUDIO_EXTN_FORMATS_ENABLED
+endif
+
+ifeq ($(strip $(AUDIO_FEATURE_ENABLED_HDMI_SPK)),true)
+LOCAL_CFLAGS += -DAUDIO_EXTN_HDMI_SPK_ENABLED
+endif
+
+ifeq ($(strip $(AUDIO_FEATURE_ENABLED_PROXY_DEVICE)),true)
+LOCAL_CFLAGS += -DAUDIO_EXTN_AFE_PROXY_ENABLED
+endif
+
 LOCAL_MODULE := libaudiopolicymanager
 
 include $(BUILD_SHARED_LIBRARY)