blob: 2d91031a386f6222362576c2b47bbbf11360c4a4 [file] [log] [blame]
Naresh Tanniruf1290152018-11-27 12:16:45 +05301ifneq ($(AUDIO_USE_STUB_HAL), true)
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -08002LOCAL_PATH:= $(call my-dir)
3
4include $(CLEAR_VARS)
5
Arun Mirpurib1bec9c2019-01-29 16:42:45 -08006LOCAL_CFLAGS := -DLIB_AUDIO_HAL="/vendor/lib/hw/audio.primary."$(TARGET_BOARD_PLATFORM)".so"
Soumil Shah196157e2018-01-22 17:39:48 -08007LOCAL_CFLAGS += -Wno-unused-variable
8LOCAL_CFLAGS += -Wno-sign-compare
9LOCAL_CFLAGS += -Wno-unused-parameter
10LOCAL_CFLAGS += -Wno-unused-label
11LOCAL_CFLAGS += -Wno-gnu-designator
12LOCAL_CFLAGS += -Wno-typedef-redefinition
13LOCAL_CFLAGS += -Wno-shorten-64-to-32
14LOCAL_CFLAGS += -Wno-tautological-compare
15LOCAL_CFLAGS += -Wno-unused-function
16LOCAL_CFLAGS += -Wno-unused-local-typedef
17LOCAL_CFLAGS += -Wno-format
Abhishek Arpurece112352018-01-31 21:29:03 +053018LOCAL_CFLAGS += -Wno-unused-value
Aalique Grahame22e49102018-12-18 14:23:57 -080019LOCAL_CFLAGS += -Wall
20LOCAL_CFLAGS += -Werror
Soumil Shah196157e2018-01-22 17:39:48 -080021
Mingming Yina6dad602014-05-16 12:10:55 -070022ifeq ($(strip $(AUDIO_FEATURE_ENABLED_PROXY_DEVICE)),true)
Mingming Yin67e34512014-04-03 17:47:22 -070023 LOCAL_CFLAGS += -DAFE_PROXY_ENABLED
24endif
25
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -080026LOCAL_SRC_FILES:= \
Aniket Kumar Lataf56b6402016-10-27 12:03:18 -070027 bundle.c \
28 equalizer.c \
29 bass_boost.c \
30 virtualizer.c \
31 reverb.c \
32 effect_api.c \
Weiyin Jiangfd19e982019-07-05 11:20:28 +080033 effect_util.c
Mingming Yin497419f2015-07-01 16:57:32 -070034
Arun Mirpurib1bec9c2019-01-29 16:42:45 -080035# HW_ACCELERATED has been disabled by default since msm8996. File doesn't
36# compile cleanly on tip so don't want to include it, but keeping this
37# as a reference.
38# LOCAL_SRC_FILES += hw_accelerator.c
Dhananjay Kumar1c978df2015-09-04 13:44:59 +053039
Vignesh Kulothunganbbf44972018-09-17 15:12:07 -070040ifeq ($(strip $(AUDIO_FEATURE_ENABLED_INSTANCE_ID)), true)
41 LOCAL_CFLAGS += -DINSTANCE_ID_ENABLED
42endif
43
Vatsal Buchac09ae062018-11-14 13:25:08 +053044ifeq ($(strip $(AUDIO_FEATURE_ENABLED_GCOV)),true)
45 LOCAL_CFLAGS += --coverage -fprofile-arcs -ftest-coverage
46 LOCAL_CPPFLAGS += --coverage -fprofile-arcs -ftest-coverage
47 LOCAL_STATIC_LIBRARIES += libprofile_rt
48endif
49
Vignesh Kulothungan9f86d7a2018-09-17 15:12:07 -070050ifeq ($(strip $(AUDIO_FEATURE_ENABLED_INSTANCE_ID)), true)
51 LOCAL_CFLAGS += -DINSTANCE_ID_ENABLED
52endif
53
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -080054LOCAL_CFLAGS+= -O2 -fvisibility=hidden
55
Jitendra Naruka1b6513f2014-11-22 19:34:13 -080056ifneq ($(strip $(AUDIO_FEATURE_DISABLED_DTS_EAGLE)),true)
57 LOCAL_CFLAGS += -DDTS_EAGLE
58endif
59
Revathi Uddarajue8bd13c2018-04-02 21:27:54 +053060LOCAL_HEADER_LIBRARIES := libhardware_headers \
61 libsystem_headers \
62 libutils_headers
63
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -080064LOCAL_SHARED_LIBRARIES := \
Aniket Kumar Lataf56b6402016-10-27 12:03:18 -070065 libcutils \
66 liblog \
67 libtinyalsa \
68 libdl
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -080069
70LOCAL_MODULE_TAGS := optional
71
Apoorv Raghuvanshi1b555f72014-05-29 12:48:15 -070072LOCAL_MODULE_RELATIVE_PATH := soundfx
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -080073LOCAL_MODULE:= libqcompostprocbundle
Naresh Tanniru10758b62017-06-05 21:05:53 +053074LOCAL_VENDOR_MODULE := true
Aalique Grahame22e49102018-12-18 14:23:57 -080075LOCAL_MODULE_OWNER := qti
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -080076
Subhash Chandra Bose Naripeddye40a7cd2014-06-03 19:42:41 -070077LOCAL_ADDITIONAL_DEPENDENCIES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr
78
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -080079LOCAL_C_INCLUDES := \
Aniket Kumar Lataf56b6402016-10-27 12:03:18 -070080 external/tinyalsa/include \
Aniket Kumar Lata808e8d62019-01-28 22:54:28 -080081 vendor/qcom/opensource/audio-hal/primary-hal/hal \
Subhash Chandra Bose Naripeddy090a2aa2014-01-30 14:03:12 -080082 $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/include \
Vignesh Kulothunganc49bdfa2020-01-08 14:24:17 -080083 $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/include/audio \
Asish Bhattacharya0b9bfb02017-07-15 08:39:36 +053084 $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/techpack/audio/include \
Arun Mirpurib1bec9c2019-01-29 16:42:45 -080085 $(call include-path-for, audio-effects) \
86 vendor/qcom/opensource/audio-hal/primary-hal/hal/audio_extn/
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -080087
Satish Babu Patakokila2787cee2018-03-22 11:18:42 +053088ifeq ($(strip $(AUDIO_FEATURE_ENABLED_DLKM)),true)
Revathi Uddaraju3f4cfa42018-06-04 20:35:10 +053089 LOCAL_HEADER_LIBRARIES += audio_kernel_headers
Asish Bhattacharyad0665872017-09-07 19:46:29 +053090 LOCAL_C_INCLUDES += $(TARGET_OUT_INTERMEDIATES)/vendor/qcom/opensource/audio-kernel/include
Asish Bhattacharyad0665872017-09-07 19:46:29 +053091endif
92
Srinivas Rao Narne8ff4db52018-01-25 16:04:44 -080093ifeq ($(TARGET_COMPILE_WITH_MSM_KERNEL),true)
94 LOCAL_C_INCLUDES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/techpack/audio/include
Satish Babu Patakokila1d3b15d2018-07-03 17:09:40 +053095 LOCAL_ADDITIONAL_DEPENDENCIES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr
Srinivas Rao Narne8ff4db52018-01-25 16:04:44 -080096endif
97
Deepthi Gunturi6167e2b2020-04-10 09:52:53 +053098ifneq ($(filter kona lahaina holi,$(TARGET_BOARD_PLATFORM)),)
Vikram Panduranga6ff1c952019-08-07 13:33:01 -070099LOCAL_SANITIZE := integer_overflow
100endif
Subhash Chandra Bose Naripeddy3eedc002013-11-12 20:45:15 -0800101include $(BUILD_SHARED_LIBRARY)
Subhash Chandra Bose Naripeddye40a7cd2014-06-03 19:42:41 -0700102
103
104ifeq ($(strip $(AUDIO_FEATURE_ENABLED_HW_ACCELERATED_EFFECTS)),true)
105include $(CLEAR_VARS)
106
Soumil Shah196157e2018-01-22 17:39:48 -0800107LOCAL_CFLAGS += -Wno-unused-variable
108LOCAL_CFLAGS += -Wno-sign-compare
109LOCAL_CFLAGS += -Wno-unused-parameter
110LOCAL_CFLAGS += -Wno-unused-label
111LOCAL_CFLAGS += -Wno-gnu-designator
112LOCAL_CFLAGS += -Wno-typedef-redefinition
113LOCAL_CFLAGS += -Wno-shorten-64-to-32
114LOCAL_CFLAGS += -Wno-tautological-compare
115LOCAL_CFLAGS += -Wno-unused-function
116LOCAL_CFLAGS += -Wno-unused-local-typedef
117LOCAL_CFLAGS += -Wno-format
Subhash Chandra Bose Naripeddye40a7cd2014-06-03 19:42:41 -0700118LOCAL_SRC_FILES := EffectsHwAcc.cpp
119
120LOCAL_C_INCLUDES := \
121 $(call include-path-for, audio-effects)
122
Revathi Uddarajue8bd13c2018-04-02 21:27:54 +0530123LOCAL_HEADER_LIBRARIES := libhardware_headers \
124 libsystem_headers \
125 libutils_headers
126
Subhash Chandra Bose Naripeddye40a7cd2014-06-03 19:42:41 -0700127LOCAL_SHARED_LIBRARIES := \
128 liblog \
129 libeffects
130
131LOCAL_MODULE_TAGS := optional
132
133LOCAL_CFLAGS += -O2 -fvisibility=hidden
134
Alexy Josephd464f3b2014-11-18 16:14:41 -0800135ifeq ($(strip $(AUDIO_FEATURE_ENABLED_DTS_EAGLE)), true)
136LOCAL_CFLAGS += -DHW_ACC_HPX
137endif
138
Subhash Chandra Bose Naripeddye40a7cd2014-06-03 19:42:41 -0700139LOCAL_MODULE:= libhwacceffectswrapper
Naresh Tanniru10758b62017-06-05 21:05:53 +0530140LOCAL_VENDOR_MODULE := true
Subhash Chandra Bose Naripeddye40a7cd2014-06-03 19:42:41 -0700141
Deepthi Gunturi6167e2b2020-04-10 09:52:53 +0530142ifneq ($(filter kona lahaina holi,$(TARGET_BOARD_PLATFORM)),)
Vikram Panduranga6ff1c952019-08-07 13:33:01 -0700143LOCAL_SANITIZE := unsigned-integer-overflow signed-integer-overflow
144endif
Subhash Chandra Bose Naripeddye40a7cd2014-06-03 19:42:41 -0700145include $(BUILD_STATIC_LIBRARY)
146endif
vivek mehta341b6f02015-06-15 16:16:11 -0700147
148
Soumil Shah196157e2018-01-22 17:39:48 -0800149
vivek mehta341b6f02015-06-15 16:16:11 -0700150################################################################################
151
Deepthi Gunturi6167e2b2020-04-10 09:52:53 +0530152ifneq ($(filter msm8992 msm8994 msm8996 msm8998 sdm660 sdm845 apq8098_latv sdm710 msm8953 msm8937 qcs605 sdmshrike msmnile kona lahaina holi atoll $(MSMSTEPPE) $(TRINKET) lito,$(TARGET_BOARD_PLATFORM)),)
vivek mehta341b6f02015-06-15 16:16:11 -0700153
154include $(CLEAR_VARS)
155
Naresh Tanniru10758b62017-06-05 21:05:53 +0530156LOCAL_CFLAGS := -DLIB_AUDIO_HAL="/vendor/lib/hw/audio.primary."$(TARGET_BOARD_PLATFORM)".so"
Soumil Shah196157e2018-01-22 17:39:48 -0800157LOCAL_CFLAGS += -Wno-unused-variable
158LOCAL_CFLAGS += -Wno-sign-compare
159LOCAL_CFLAGS += -Wno-unused-parameter
160LOCAL_CFLAGS += -Wno-unused-label
161LOCAL_CFLAGS += -Wno-gnu-designator
162LOCAL_CFLAGS += -Wno-typedef-redefinition
163LOCAL_CFLAGS += -Wno-shorten-64-to-32
164LOCAL_CFLAGS += -Wno-tautological-compare
165LOCAL_CFLAGS += -Wno-unused-function
166LOCAL_CFLAGS += -Wno-unused-local-typedef
167LOCAL_CFLAGS += -Wno-format
Aalique Grahame22e49102018-12-18 14:23:57 -0800168LOCAL_CFLAGS += -Wall
169LOCAL_CFLAGS += -Werror
vivek mehta341b6f02015-06-15 16:16:11 -0700170
171LOCAL_SRC_FILES:= \
172 volume_listener.c
173
174LOCAL_CFLAGS+= -O2 -fvisibility=hidden
175
Revathi Uddarajue8bd13c2018-04-02 21:27:54 +0530176LOCAL_HEADER_LIBRARIES := libhardware_headers \
177 libsystem_headers \
178 libutils_headers
179
vivek mehta341b6f02015-06-15 16:16:11 -0700180LOCAL_SHARED_LIBRARIES := \
181 libcutils \
182 liblog \
Aalique Grahame22e49102018-12-18 14:23:57 -0800183 libdl \
184 libaudioutils
vivek mehta341b6f02015-06-15 16:16:11 -0700185
186LOCAL_MODULE_RELATIVE_PATH := soundfx
187LOCAL_MODULE:= libvolumelistener
Naresh Tanniru10758b62017-06-05 21:05:53 +0530188LOCAL_VENDOR_MODULE := true
Aalique Grahame22e49102018-12-18 14:23:57 -0800189LOCAL_MODULE_OWNER := qti
vivek mehta341b6f02015-06-15 16:16:11 -0700190
Aniket Kumar Lata8e743e62017-08-14 12:36:47 -0700191LOCAL_ADDITIONAL_DEPENDENCIES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr
192
vivek mehta341b6f02015-06-15 16:16:11 -0700193LOCAL_C_INCLUDES := \
vivek mehtaa24d1ad2019-01-15 22:38:01 -0800194 vendor/qcom/opensource/audio-hal/primary-hal/hal \
Aniket Kumar Lataf56b6402016-10-27 12:03:18 -0700195 $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/include \
Vignesh Kulothunganc49bdfa2020-01-08 14:24:17 -0800196 $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/include/audio \
Aniket Kumar Lata8e743e62017-08-14 12:36:47 -0700197 $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/techpack/audio/include \
Aniket Kumar Lataf56b6402016-10-27 12:03:18 -0700198 external/tinyalsa/include \
199 $(call include-path-for, audio-effects) \
200 $(call include-path-for, audio-route) \
vivek mehtaa24d1ad2019-01-15 22:38:01 -0800201 vendor/qcom/opensource/audio-hal/primary-hal/hal/audio_extn \
Aalique Grahame22e49102018-12-18 14:23:57 -0800202 external/tinycompress/include \
203 system/media/audio_utils/include
vivek mehta341b6f02015-06-15 16:16:11 -0700204
Satish Babu Patakokila2787cee2018-03-22 11:18:42 +0530205ifeq ($(strip $(AUDIO_FEATURE_ENABLED_DLKM)),true)
Revathi Uddaraju3f4cfa42018-06-04 20:35:10 +0530206 LOCAL_HEADER_LIBRARIES += audio_kernel_headers
Asish Bhattacharyad0665872017-09-07 19:46:29 +0530207 LOCAL_C_INCLUDES += $(TARGET_OUT_INTERMEDIATES)/vendor/qcom/opensource/audio-kernel/include
Asish Bhattacharyad0665872017-09-07 19:46:29 +0530208endif
209
Srinivas Rao Narne8ff4db52018-01-25 16:04:44 -0800210ifeq ($(TARGET_COMPILE_WITH_MSM_KERNEL),true)
211 LOCAL_C_INCLUDES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/techpack/audio/include
Satish Babu Patakokila1d3b15d2018-07-03 17:09:40 +0530212 LOCAL_ADDITIONAL_DEPENDENCIES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr
Srinivas Rao Narne8ff4db52018-01-25 16:04:44 -0800213endif
214
Deepthi Gunturi6167e2b2020-04-10 09:52:53 +0530215ifneq ($(filter kona lahaina holi,$(TARGET_BOARD_PLATFORM)),)
Vikram Panduranga6ff1c952019-08-07 13:33:01 -0700216LOCAL_SANITIZE := integer_overflow
217endif
vivek mehta341b6f02015-06-15 16:16:11 -0700218include $(BUILD_SHARED_LIBRARY)
219
220endif
jasmine cha75fa6f02018-03-30 15:41:33 +0800221
222################################################################################
223ifeq ($(strip $(AUDIO_FEATURE_ENABLED_MAXX_AUDIO)), true)
224
225include $(CLEAR_VARS)
226
227LOCAL_CFLAGS := -D HAL_LIB_NAME=\"audio.primary."$(TARGET_BOARD_PLATFORM)".so\"
228
229LOCAL_SRC_FILES:= \
Aalique Grahame5ce7fbe2019-01-28 12:08:13 -0800230 ma_listener.c
jasmine cha75fa6f02018-03-30 15:41:33 +0800231
232LOCAL_CFLAGS += $(qcom_post_proc_common_cflags)
233
234LOCAL_SHARED_LIBRARIES := \
Aalique Grahame5ce7fbe2019-01-28 12:08:13 -0800235 libcutils \
236 liblog \
237 libdl
jasmine cha75fa6f02018-03-30 15:41:33 +0800238
239LOCAL_MODULE_RELATIVE_PATH := soundfx
240LOCAL_MODULE:= libmalistener
241LOCAL_MODULE_OWNER := google
242LOCAL_PROPRIETARY_MODULE := true
243
244LOCAL_C_INCLUDES := \
Aalique Grahame5ce7fbe2019-01-28 12:08:13 -0800245 hardware/qcom/audio/hal \
246 system/media/audio/include/system \
247 $(call include-path-for, audio-effects)
jasmine cha75fa6f02018-03-30 15:41:33 +0800248
249LOCAL_HEADER_LIBRARIES += libhardware_headers
250LOCAL_HEADER_LIBRARIES += libsystem_headers
Deepthi Gunturi6167e2b2020-04-10 09:52:53 +0530251ifneq ($(filter kona lahaina holi,$(TARGET_BOARD_PLATFORM)),)
Vikram Panduranga6ff1c952019-08-07 13:33:01 -0700252LOCAL_SANITIZE := integer_overflow
253endif
jasmine cha75fa6f02018-03-30 15:41:33 +0800254include $(BUILD_SHARED_LIBRARY)
255
256endif
Naresh Tanniruf1290152018-11-27 12:16:45 +0530257endif