blob: 1756e471795cd89db03c792bb1dc5b05c9b426a6 [file] [log] [blame]
Steven Moreland22ee4602017-04-07 10:44:52 -07001// Copyright 2017 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
Bob Badour56786ac2021-02-25 15:24:36 -080015package {
16 // See: http://go/android-license-faq
17 // A large-scale-change added 'default_applicable_licenses' to import
18 // all of the 'license_kinds' from "frameworks_av_license"
19 // to get the below license kinds:
20 // SPDX-license-identifier-Apache-2.0
21 default_applicable_licenses: ["frameworks_av_license"],
22}
23
Wei Jia4049f132018-01-22 10:37:31 -080024cc_library {
Steven Moreland22ee4602017-04-07 10:44:52 -070025 name: "libmediautils",
26
27 srcs: [
Jayant Chowdhary32b4f492018-11-14 18:38:21 -080028 "AImageReaderUtils.cpp",
Steven Moreland22ee4602017-04-07 10:44:52 -070029 "BatteryNotifier.cpp",
30 "ISchedulingPolicyService.cpp",
Andy Hungd7e0dd42020-03-27 16:42:34 -070031 "LimitProcessMemory.cpp",
Steven Moreland22ee4602017-04-07 10:44:52 -070032 "MemoryLeakTrackUtil.cpp",
Andy Hung224f82f2022-03-22 00:00:49 -070033 "MethodStatistics.cpp",
Steven Moreland22ee4602017-04-07 10:44:52 -070034 "ProcessInfo.cpp",
35 "SchedulingPolicyService.cpp",
Andy Hungab7ef302018-05-15 19:35:29 -070036 "ServiceUtilities.cpp",
Eric Laurent39b09b52018-06-29 12:24:40 -070037 "TimeCheck.cpp",
Ytai Ben-Tsvi1ea62c92021-11-10 14:38:27 -080038 "TimerThread.cpp",
Steven Moreland22ee4602017-04-07 10:44:52 -070039 ],
Colin Crossd8e3af02019-05-17 13:28:13 -070040 static_libs: [
41 "libc_malloc_debug_backtrace",
Steven Moreland36960002021-04-01 00:08:45 +000042 "libbatterystats_aidl",
Steven Moreland886d7322021-04-02 04:19:45 +000043 "libprocessinfoservice_aidl",
Colin Crossd8e3af02019-05-17 13:28:13 -070044 ],
Steven Moreland22ee4602017-04-07 10:44:52 -070045 shared_libs: [
Philip P. Moltmannbda45752020-07-17 16:41:18 -070046 "libaudioclient_aidl_conversion",
Andy Hungc747c532022-03-07 21:41:14 -080047 "libaudioutils", // for clock.h, Statistics.h
Steven Moreland22ee4602017-04-07 10:44:52 -070048 "libbinder",
Jeffrey Carlyle62cc92b2019-09-17 11:15:15 -070049 "libcutils",
Steven Moreland22ee4602017-04-07 10:44:52 -070050 "liblog",
51 "libutils",
Andy Hung10ac7112022-03-28 08:00:40 -070052 "libutilscallstack",
Jayant Chowdhary32b4f492018-11-14 18:38:21 -080053 "libhidlbase",
Svet Ganov33761132021-05-13 22:51:08 +000054 "libpermission",
Jayant Chowdhary32b4f492018-11-14 18:38:21 -080055 "android.hardware.graphics.bufferqueue@1.0",
56 "android.hidl.token@1.0-utils",
Samiul Islamacb722d2021-08-26 11:41:21 +010057 "packagemanager_aidl-cpp",
Steven Moreland22ee4602017-04-07 10:44:52 -070058 ],
Steven Moreland36960002021-04-01 00:08:45 +000059 export_static_lib_headers: [
60 "libbatterystats_aidl",
61 ],
Steven Moreland22ee4602017-04-07 10:44:52 -070062
Eric Laurent39b09b52018-06-29 12:24:40 -070063 logtags: ["EventLogTags.logtags"],
64
Steven Moreland22ee4602017-04-07 10:44:52 -070065 cflags: [
66 "-Wall",
67 "-Wextra",
68 "-Werror",
69 ],
70
Christopher Ferris9d2e0082019-09-11 19:08:13 -070071 header_libs: [
72 "bionic_libc_platform_headers",
Marco Nelissen6b285942019-10-21 14:52:30 -070073 "libmedia_headers",
Christopher Ferrisa90adf02019-04-17 13:26:15 -070074 ],
Christopher Ferris9d2e0082019-09-11 19:08:13 -070075
Philip P. Moltmannbda45752020-07-17 16:41:18 -070076 export_shared_lib_headers: [
Svet Ganov33761132021-05-13 22:51:08 +000077 "libpermission",
Philip P. Moltmannbda45752020-07-17 16:41:18 -070078 ],
79
Eric Laurent42896a02019-09-27 15:40:33 -070080 include_dirs: [
81 // For DEBUGGER_SIGNAL
82 "system/core/debuggerd/include",
83 ],
Steven Moreland22ee4602017-04-07 10:44:52 -070084 local_include_dirs: ["include"],
85 export_include_dirs: ["include"],
86}
Andy Hung328d6772021-01-12 12:32:21 -080087
Andy Hung61589a42021-06-16 09:37:53 -070088cc_library {
89 name: "libmediautils_vendor",
90 vendor_available: true, // required for platform/hardware/interfaces
91 srcs: [
92 "MemoryLeakTrackUtil.cpp",
93 ],
94
95 cflags: [
96 "-Wall",
97 "-Wextra",
98 "-Werror",
99 ],
100 shared_libs: [
101 "liblog",
102 "libutils",
103 ],
104
105 static_libs: [
106 "libc_malloc_debug_backtrace",
107 ],
108
109 header_libs: [
110 "bionic_libc_platform_headers",
111 ],
112
113 local_include_dirs: ["include"],
114 export_include_dirs: ["include"],
115}
116
117
Andy Hung328d6772021-01-12 12:32:21 -0800118cc_library_headers {
119 name: "libmediautils_headers",
120 vendor_available: true, // required for platform/hardware/interfaces
121
122 export_include_dirs: ["include"],
123}
Ytai Ben-Tsvi1ea62c92021-11-10 14:38:27 -0800124
125cc_test {
126 name: "libmediautils_test",
Ytai Ben-Tsvidb6f8982022-02-07 12:06:23 -0800127 srcs: [
128 "memory-test.cpp",
129 "TimerThread-test.cpp",
130 ],
Ytai Ben-Tsvi1ea62c92021-11-10 14:38:27 -0800131 shared_libs: [
132 "libmediautils",
133 "libutils",
134 ]
135}