blob: 12cd68c1ba0aa3b73756b5a50b6a4b3233ed311f
1 | # Copyright (C) 2011 The Android Open Source Project |
2 | # |
3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
4 | # you may not use this file except in compliance with the License. |
5 | # You may obtain a copy of the License at |
6 | # |
7 | # http://www.apache.org/licenses/LICENSE-2.0 |
8 | # |
9 | # Unless required by applicable law or agreed to in writing, software |
10 | # distributed under the License is distributed on an "AS IS" BASIS, |
11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
12 | # See the License for the specific language governing permissions and |
13 | # limitations under the License. |
14 | |
15 | ifeq ($(strip $(BOARD_ALSA_AUDIO)),tiny) |
16 | |
17 | LOCAL_PATH := $(call my-dir) |
18 | |
19 | # The default audio HAL module, which is a stub, that is loaded if no other |
20 | # device specific modules are present. The exact load order can be seen in |
21 | # libhardware/hardware.c |
22 | # |
23 | # The format of the name is audio.<type>.<hardware/etc>.so where the only |
24 | # required type is 'primary'. Other possibilites are 'a2dp', 'usb', etc. |
25 | include $(CLEAR_VARS) |
26 | |
27 | LOCAL_MODULE := audio.primary.amlogic |
28 | LOCAL_MODULE_RELATIVE_PATH := hw |
29 | LOCAL_SRC_FILES := \ |
30 | audio_hw.c \ |
31 | libTVaudio/audio/audio_effect_control.c \ |
32 | audio_hw_utils.c \ |
33 | audio_hwsync.c \ |
34 | spdifenc_wrap.cpp \ |
35 | audio_hw_profile.c |
36 | LOCAL_C_INCLUDES += \ |
37 | external/tinyalsa/include \ |
38 | system/media/audio_utils/include \ |
39 | system/media/audio_effects/include \ |
40 | system/media/audio_route/include \ |
41 | libTVaudio/audio |
42 | |
43 | LOCAL_SHARED_LIBRARIES := \ |
44 | liblog libcutils libtinyalsa \ |
45 | libaudioutils libdl libaudioroute libutils \ |
46 | libaudiospdif |
47 | LOCAL_MODULE_TAGS := optional |
48 | |
49 | include $(BUILD_SHARED_LIBRARY) |
50 | |
51 | #build for USB audio |
52 | ifeq ($(strip $(BOARD_USE_USB_AUDIO)),true) |
53 | include $(CLEAR_VARS) |
54 | |
55 | LOCAL_MODULE := audio.usb.amlogic |
56 | LOCAL_MODULE_RELATIVE_PATH := hw |
57 | LOCAL_SRC_FILES := \ |
58 | usb_audio_hw.c \ |
59 | audio_resampler.c |
60 | LOCAL_C_INCLUDES += \ |
61 | external/tinyalsa/include \ |
62 | system/media/audio_utils/include |
63 | LOCAL_SHARED_LIBRARIES := liblog libcutils libtinyalsa libaudioutils libutils |
64 | LOCAL_MODULE_TAGS := optional |
65 | |
66 | include $(BUILD_SHARED_LIBRARY) |
67 | endif # BOARD_USE_USB_AUDIO |
68 | |
69 | #build for hdmi audio HAL |
70 | ifeq ($(strip $(BOARD_USE_HDMI_HAL)),true) |
71 | include $(CLEAR_VARS) |
72 | |
73 | LOCAL_MODULE := audio.hdmi.amlogic |
74 | LOCAL_MODULE_RELATIVE_PATH := hw |
75 | LOCAL_SRC_FILES := \ |
76 | hdmi_audio_hw.c |
77 | LOCAL_C_INCLUDES += \ |
78 | external/tinyalsa/include \ |
79 | system/media/audio_effects/include \ |
80 | system/media/audio_utils/include |
81 | |
82 | LOCAL_SHARED_LIBRARIES := liblog libcutils libtinyalsa libaudioutils libutils |
83 | #ifdef DOLBY_UDC_PASSTHROUGH_HDMI_PACK |
84 | LOCAL_SRC_FILES += spdifenc_wrap.cpp |
85 | LOCAL_C_INCLUDES += \ |
86 | $(call include-path-for, audio-utils) |
87 | LOCAL_SHARED_LIBRARIES += \ |
88 | libaudiospdif |
89 | #endif # DOLBY_UDC_PASSTHROUGH_HDMI_PACK |
90 | ifdef DOLBY_EAC3_TO_AC3_CONVERTER |
91 | LOCAL_SHARED_LIBRARIES += \ |
92 | libdlb_converter |
93 | endif # DOLBY_EAC3_TO_AC3_CONVERTER |
94 | LOCAL_SRC_FILES += audio_hw_profile.c |
95 | LOCAL_SRC_FILES += audio_hw_utils.c |
96 | LOCAL_SRC_FILES += audio_hwsync.c |
97 | LOCAL_MODULE_TAGS := optional |
98 | include $(BUILD_SHARED_LIBRARY) |
99 | endif # BOARD_USE_HDMI_HAL |
100 | endif # BOARD_ALSA_AUDIO |
101 | |
102 | ######################################################### |
103 | # Audio Policy Manager |
104 | ifeq ($(USE_CUSTOM_AUDIO_POLICY),1) |
105 | include $(CLEAR_VARS) |
106 | |
107 | LOCAL_SRC_FILES := \ |
108 | DLGAudioPolicyManager.cpp |
109 | |
110 | LOCAL_SHARED_LIBRARIES := \ |
111 | libcutils \ |
112 | liblog \ |
113 | libutils \ |
114 | libmedia \ |
115 | libbinder \ |
116 | libaudiopolicymanagerdefault \ |
117 | libutils |
118 | |
119 | LOCAL_C_INCLUDES := \ |
120 | external/tinyalsa/include \ |
121 | $(TOPDIR)frameworks/av/services/audiopolicy \ |
122 | $(TOPDIR)frameworks/av/services/audiopolicy/managerdefault \ |
123 | $(TOPDIR)frameworks/av/services/audiopolicy/engine/interface \ |
124 | $(TOPDIR)frameworks/av/services/audiopolicy/common/managerdefinitions/include \ |
125 | $(TOPDIR)frameworks/av/services/audiopolicy/common/include |
126 | |
127 | |
128 | LOCAL_MODULE := libaudiopolicymanager |
129 | LOCAL_MODULE_TAGS := optional |
130 | |
131 | include $(BUILD_SHARED_LIBRARY) |
132 | endif # USE_CUSTOM_AUDIO_POLICY |
133 | |
134 | include $(call all-makefiles-under,$(LOCAL_PATH)) |
135 |