summaryrefslogtreecommitdiff
path: root/Android.mk (plain)
blob: 1c36d8fd51dfce22d7d8652340b4f2a07d11adee
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
15ifeq ($(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 LOCAL_C_INCLUDES += \
36 external/tinyalsa/include \
37 system/media/audio_utils/include \
38 system/media/audio_effects/include \
39 system/media/audio_route/include \
40 libTVaudio/audio
41
42 LOCAL_SHARED_LIBRARIES := \
43 liblog libcutils libtinyalsa \
44 libaudioutils libdl libaudioroute libutils \
45 libaudiospdif
46 LOCAL_MODULE_TAGS := optional
47
48 include $(BUILD_SHARED_LIBRARY)
49#build for USB audio
50 ifeq ($(strip $(BOARD_USE_USB_AUDIO)),true)
51 include $(CLEAR_VARS)
52
53 LOCAL_MODULE := audio.usb.amlogic
54 LOCAL_MODULE_RELATIVE_PATH := hw
55 LOCAL_SRC_FILES := \
56 usb_audio_hw.c \
57 audio_resampler.c
58 LOCAL_C_INCLUDES += \
59 external/tinyalsa/include \
60 system/media/audio_utils/include
61 LOCAL_SHARED_LIBRARIES := liblog libcutils libtinyalsa libaudioutils libutils
62 LOCAL_MODULE_TAGS := optional
63
64 include $(BUILD_SHARED_LIBRARY)
65 endif
66#build for hdmi audio HAL
67ifeq ($(strip $(BOARD_USE_HDMI_HAL)),true)
68 #ifneq ($(strip $(BOARD_USE_HDMI_HAL)),true)
69 include $(CLEAR_VARS)
70
71 LOCAL_MODULE := audio.hdmi.amlogic
72 LOCAL_MODULE_RELATIVE_PATH := hw
73 LOCAL_SRC_FILES := \
74 hdmi_audio_hw.c
75 LOCAL_C_INCLUDES += \
76 external/tinyalsa/include \
77 system/media/audio_effects/include \
78 system/media/audio_utils/include
79
80 LOCAL_SHARED_LIBRARIES := liblog libcutils libtinyalsa libaudioutils libutils
81#ifdef DOLBY_UDC_PASSTHROUGH_HDMI_PACK
82LOCAL_SRC_FILES += spdifenc_wrap.cpp
83LOCAL_C_INCLUDES += \
84 $(call include-path-for, audio-utils)
85LOCAL_SHARED_LIBRARIES += \
86 libaudiospdif
87#endif # DOLBY_UDC_PASSTHROUGH_HDMI_PACK
88ifdef DOLBY_EAC3_TO_AC3_CONVERTER
89LOCAL_SHARED_LIBRARIES += \
90 libdlb_converter
91endif
92LOCAL_SRC_FILES += audio_hw_profile.c
93LOCAL_SRC_FILES += audio_hw_utils.c
94LOCAL_SRC_FILES += audio_hwsync.c
95LOCAL_MODULE_TAGS := optional
96include $(BUILD_SHARED_LIBRARY)
97 endif
98endif # BOARD_ALSA_AUDIO
99include $(call all-makefiles-under,$(LOCAL_PATH))
100