summaryrefslogtreecommitdiffstats
path: root/libaudio
diff options
context:
space:
mode:
authorDima Zavin <dima@android.com>2011-04-20 01:22:02 -0700
committerDima Zavin <dima@android.com>2011-04-20 01:22:02 -0700
commit99ba13543a75bf29ff42ba13e958435bb927b5d4 (patch)
tree7f2852340e55e3857faf963e3ea3d0c128f8f59d /libaudio
parentc5617a959499f793b1b79ea49768a74a929a6f8a (diff)
downloaddevice_samsung_crespo-99ba13543a75bf29ff42ba13e958435bb927b5d4.zip
device_samsung_crespo-99ba13543a75bf29ff42ba13e958435bb927b5d4.tar.gz
device_samsung_crespo-99ba13543a75bf29ff42ba13e958435bb927b5d4.tar.bz2
crespo/audio: build hal modules instead of libaudio
Change-Id: Ia4134c310a8e854d85c3584907a4da07355cc2b3 Signed-off-by: Dima Zavin <dima@android.com>
Diffstat (limited to 'libaudio')
-rw-r--r--libaudio/Android.mk30
-rw-r--r--libaudio/AudioHardware.cpp2
-rw-r--r--libaudio/AudioHardware.h9
-rw-r--r--libaudio/AudioPolicyManager.cpp2
-rw-r--r--libaudio/AudioPolicyManager.h2
5 files changed, 27 insertions, 18 deletions
diff --git a/libaudio/Android.mk b/libaudio/Android.mk
index 726859b..9dbe57d 100644
--- a/libaudio/Android.mk
+++ b/libaudio/Android.mk
@@ -1,7 +1,5 @@
LOCAL_PATH:= $(call my-dir)
-ifneq ($(filter crespo crespo4g,$(TARGET_DEVICE)),)
-
include $(CLEAR_VARS)
LOCAL_SRC_FILES:= aplay.c alsa_pcm.c alsa_mixer.c
LOCAL_MODULE:= aplay
@@ -25,12 +23,12 @@ include $(BUILD_EXECUTABLE)
include $(CLEAR_VARS)
LOCAL_SRC_FILES:= AudioHardware.cpp alsa_mixer.c alsa_pcm.c
-LOCAL_MODULE:= libaudio
-LOCAL_STATIC_LIBRARIES:= libaudiointerface
-LOCAL_SHARED_LIBRARIES:= libc libcutils libutils libmedia libhardware_legacy
-ifeq ($(BOARD_HAVE_BLUETOOTH),true)
- LOCAL_SHARED_LIBRARIES += liba2dp
-endif
+LOCAL_MODULE := audio.primary.herring
+LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw
+LOCAL_STATIC_LIBRARIES:= libmedia_helper
+LOCAL_SHARED_LIBRARIES:= libcutils libutils libmedia libhardware_legacy
+LOCAL_WHOLE_STATIC_LIBRARIES := libaudiohw_legacy
+LOCAL_MODULE_TAGS := optional
ifeq ($(TARGET_SIMULATOR),true)
LOCAL_LDLIBS += -ldl
@@ -41,13 +39,17 @@ endif
include $(BUILD_SHARED_LIBRARY)
include $(CLEAR_VARS)
-LOCAL_SRC_FILES:= AudioPolicyManager.cpp
-LOCAL_MODULE:= libaudiopolicy
-LOCAL_STATIC_LIBRARIES:= libaudiopolicybase
-LOCAL_SHARED_LIBRARIES:= libc libcutils libutils libmedia
+
+LOCAL_SRC_FILES := AudioPolicyManager.cpp
+LOCAL_SHARED_LIBRARIES := libcutils libutils libmedia
+LOCAL_STATIC_LIBRARIES := libmedia_helper
+LOCAL_WHOLE_STATIC_LIBRARIES := libaudiopolicy_legacy
+LOCAL_MODULE := audio_policy.herring
+LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw
+LOCAL_MODULE_TAGS := optional
+
ifeq ($(BOARD_HAVE_BLUETOOTH),true)
LOCAL_CFLAGS += -DWITH_A2DP
endif
-include $(BUILD_SHARED_LIBRARY)
-endif
+include $(BUILD_SHARED_LIBRARY)
diff --git a/libaudio/AudioHardware.cpp b/libaudio/AudioHardware.cpp
index eee5f17..777b6eb 100644
--- a/libaudio/AudioHardware.cpp
+++ b/libaudio/AudioHardware.cpp
@@ -41,7 +41,7 @@ extern "C" {
}
-namespace android {
+namespace android_audio_legacy {
const uint32_t AudioHardware::inputSamplingRates[] = {
8000, 11025, 16000, 22050, 44100
diff --git a/libaudio/AudioHardware.h b/libaudio/AudioHardware.h
index fb94e95..dc83921 100644
--- a/libaudio/AudioHardware.h
+++ b/libaudio/AudioHardware.h
@@ -34,7 +34,14 @@ extern "C" {
struct mixer_ctl;
};
-namespace android {
+namespace android_audio_legacy {
+ using android::AutoMutex;
+ using android::Mutex;
+ using android::RefBase;
+ using android::SortedVector;
+ using android::sp;
+ using android::String16;
+ using android::Vector;
// TODO: determine actual audio DSP and hardware latency
// Additionnal latency introduced by audio DSP and hardware in ms
diff --git a/libaudio/AudioPolicyManager.cpp b/libaudio/AudioPolicyManager.cpp
index c53d1e9..bfa6c00 100644
--- a/libaudio/AudioPolicyManager.cpp
+++ b/libaudio/AudioPolicyManager.cpp
@@ -20,7 +20,7 @@
#include "AudioPolicyManager.h"
#include <media/mediarecorder.h>
-namespace android {
+namespace android_audio_legacy {
diff --git a/libaudio/AudioPolicyManager.h b/libaudio/AudioPolicyManager.h
index 03141e5..d660e78 100644
--- a/libaudio/AudioPolicyManager.h
+++ b/libaudio/AudioPolicyManager.h
@@ -23,7 +23,7 @@
#include <hardware_legacy/AudioPolicyManagerBase.h>
-namespace android {
+namespace android_audio_legacy {
class AudioPolicyManager: public AudioPolicyManagerBase
{