blob: bf79a2e8785f6afa0624b96fe8274b634099ca05 [file] [log] [blame]
Tao Baoe3f09a72019-10-01 11:55:36 -07001// Copyright (C) 2019 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
Tao Bao832c9cd2019-09-27 23:32:00 -070015cc_defaults {
16 name: "librecovery_utils_defaults",
17
18 defaults: [
19 "recovery_defaults",
20 ],
21
22 shared_libs: [
23 "android.hardware.health@2.0",
24 "libbase",
25 "libext4_utils",
26 "libfs_mgr",
27 "libhidlbase",
28 "libselinux",
29 "libutils",
30 ],
31
32 static_libs: [
33 "libotautil",
34
35 // External dependencies.
36 "libfstab",
37 "libhealthhalutils",
38 ],
39}
40
Tao Baoe3f09a72019-10-01 11:55:36 -070041// A utility lib that's local to recovery (in contrast, libotautil is exposed to device-specific
42// recovery_ui lib as well as device-specific updater).
43cc_library_static {
44 name: "librecovery_utils",
45
46 recovery_available: true,
47
48 defaults: [
Tao Bao832c9cd2019-09-27 23:32:00 -070049 "librecovery_utils_defaults",
Tao Baoe3f09a72019-10-01 11:55:36 -070050 ],
51
52 srcs: [
Tao Bao832c9cd2019-09-27 23:32:00 -070053 "battery_utils.cpp",
Tao Baoe3f09a72019-10-01 11:55:36 -070054 "logging.cpp",
55 "parse_install_logs.cpp",
56 "roots.cpp",
57 "thermalutil.cpp",
58 ],
59
Tao Bao640175e2019-10-01 23:24:30 -070060 header_libs: [
61 "libvold_headers",
62 ],
63
Tao Baoe3f09a72019-10-01 11:55:36 -070064 export_include_dirs: [
65 "include",
66 ],
67
Tao Baoe3f09a72019-10-01 11:55:36 -070068 export_static_lib_headers: [
Tao Bao640175e2019-10-01 23:24:30 -070069 // roots.h includes <fstab/fstab.h>.
Tao Baoe3f09a72019-10-01 11:55:36 -070070 "libfstab",
71 ],
72
73 // Should avoid exposing to the libs that might be used in device-specific codes (e.g.
74 // libedify, libotautil, librecovery_ui).
75 visibility: [
76 "//bootable/recovery",
77 "//bootable/recovery/install",
Tao Baob548bea2019-09-30 16:16:07 -070078 "//bootable/recovery/minadbd",
Tao Baoe3f09a72019-10-01 11:55:36 -070079 "//bootable/recovery/tests",
80 ],
81}