Tao Bao | e3f09a7 | 2019-10-01 11:55:36 -0700 | [diff] [blame] | 1 | // 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 Bao | 832c9cd | 2019-09-27 23:32:00 -0700 | [diff] [blame] | 15 | cc_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 Bao | e3f09a7 | 2019-10-01 11:55:36 -0700 | [diff] [blame] | 41 | // 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). |
| 43 | cc_library_static { |
| 44 | name: "librecovery_utils", |
| 45 | |
| 46 | recovery_available: true, |
| 47 | |
| 48 | defaults: [ |
Tao Bao | 832c9cd | 2019-09-27 23:32:00 -0700 | [diff] [blame] | 49 | "librecovery_utils_defaults", |
Tao Bao | e3f09a7 | 2019-10-01 11:55:36 -0700 | [diff] [blame] | 50 | ], |
| 51 | |
| 52 | srcs: [ |
Tao Bao | 832c9cd | 2019-09-27 23:32:00 -0700 | [diff] [blame] | 53 | "battery_utils.cpp", |
Tao Bao | e3f09a7 | 2019-10-01 11:55:36 -0700 | [diff] [blame] | 54 | "logging.cpp", |
| 55 | "parse_install_logs.cpp", |
| 56 | "roots.cpp", |
| 57 | "thermalutil.cpp", |
| 58 | ], |
| 59 | |
Tao Bao | 640175e | 2019-10-01 23:24:30 -0700 | [diff] [blame] | 60 | header_libs: [ |
| 61 | "libvold_headers", |
| 62 | ], |
| 63 | |
Tao Bao | e3f09a7 | 2019-10-01 11:55:36 -0700 | [diff] [blame] | 64 | export_include_dirs: [ |
| 65 | "include", |
| 66 | ], |
| 67 | |
Tao Bao | e3f09a7 | 2019-10-01 11:55:36 -0700 | [diff] [blame] | 68 | export_static_lib_headers: [ |
Tao Bao | 640175e | 2019-10-01 23:24:30 -0700 | [diff] [blame] | 69 | // roots.h includes <fstab/fstab.h>. |
Tao Bao | e3f09a7 | 2019-10-01 11:55:36 -0700 | [diff] [blame] | 70 | "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", |
bigbiff | 673c7ae | 2020-12-02 19:44:56 -0500 | [diff] [blame] | 78 | "//bootable/recovery/libaosprecovery", |
Tao Bao | b548bea | 2019-09-30 16:16:07 -0700 | [diff] [blame] | 79 | "//bootable/recovery/minadbd", |
Tao Bao | e3f09a7 | 2019-10-01 11:55:36 -0700 | [diff] [blame] | 80 | "//bootable/recovery/tests", |
| 81 | ], |
| 82 | } |