1# Copyright 2016 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
15LOCAL_PATH := $(call my-dir)
16
17audio_service_shared_libraries := \
18  libbinderwrapper \
19  libbrillo \
20  libbrillo-binder \
21  libc \
22  libchrome \
23  libmedia \
24  libutils
25
26# Audio service.
27# =============================================================================
28include $(CLEAR_VARS)
29LOCAL_MODULE := brilloaudioservice
30LOCAL_SRC_FILES := \
31  audio_daemon.cpp \
32  audio_device_handler.cpp \
33  main_audio_service.cpp
34LOCAL_SHARED_LIBRARIES := $(audio_service_shared_libraries)
35LOCAL_CFLAGS := -Werror -Wall
36LOCAL_INIT_RC := brilloaudioserv.rc
37include $(BUILD_EXECUTABLE)
38
39# Unit tests for audio device handler.
40# =============================================================================
41include $(CLEAR_VARS)
42LOCAL_MODULE := brilloaudioservice_test
43LOCAL_SRC_FILES := \
44  audio_device_handler.cpp \
45  test/audio_device_handler_test.cpp
46LOCAL_C_INCLUDES := external/gtest/include
47LOCAL_SHARED_LIBRARIES := $(audio_service_shared_libraries)
48LOCAL_STATIC_LIBRARIES := \
49  libBionicGtestMain \
50  libchrome_test_helpers \
51  libgmock
52LOCAL_CFLAGS := -Werror -Wall
53LOCAL_CFLAGS += -Wno-sign-compare
54include $(BUILD_NATIVE_TEST)
55