Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 1 | // Copyright (C) 2018 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 | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 15 | cc_defaults { |
| 16 | name: "libupdater_defaults", |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 17 | |
| 18 | defaults: [ |
| 19 | "recovery_defaults", |
| 20 | ], |
| 21 | |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 22 | static_libs: [ |
| 23 | "libapplypatch", |
| 24 | "libbootloader_message", |
| 25 | "libbspatch", |
| 26 | "libedify", |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 27 | "libotautil", |
| 28 | "libext4_utils", |
Yifan Hong | 8ff84d7 | 2018-12-19 16:21:55 -0800 | [diff] [blame] | 29 | "libdm", |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 30 | "libfec", |
| 31 | "libfec_rs", |
| 32 | "libverity_tree", |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 33 | "libgtest_prod", |
| 34 | "liblog", |
Yifan Hong | 8ff84d7 | 2018-12-19 16:21:55 -0800 | [diff] [blame] | 35 | "liblp", |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 36 | "libselinux", |
| 37 | "libsparse", |
| 38 | "libsquashfs_utils", |
| 39 | "libbrotli", |
| 40 | "libbz", |
| 41 | "libziparchive", |
| 42 | "libz", |
| 43 | "libbase", |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 44 | "libcrypto_utils", |
| 45 | "libcutils", |
| 46 | "libutils", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 47 | ], |
Pete Bentley | 189d424 | 2019-09-12 19:53:46 +0100 | [diff] [blame] | 48 | |
| 49 | shared_libs: [ |
| 50 | "libcrypto", |
| 51 | ], |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 52 | } |
| 53 | |
| 54 | cc_defaults { |
| 55 | name: "libupdater_device_defaults", |
| 56 | |
| 57 | static_libs: [ |
| 58 | "libfs_mgr", |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 59 | "libtune2fs", |
| 60 | |
| 61 | "libext2_com_err", |
| 62 | "libext2_blkid", |
| 63 | "libext2_quota", |
| 64 | "libext2_uuid", |
| 65 | "libext2_e2p", |
| 66 | "libext2fs", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 67 | ] |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 68 | } |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 69 | |
| 70 | cc_library_static { |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 71 | name: "libupdater_core", |
| 72 | |
| 73 | host_supported: true, |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 74 | |
| 75 | defaults: [ |
| 76 | "recovery_defaults", |
| 77 | "libupdater_defaults", |
| 78 | ], |
| 79 | |
| 80 | srcs: [ |
| 81 | "blockimg.cpp", |
| 82 | "commands.cpp", |
| 83 | "install.cpp", |
Tianjie Xu | 58d5912 | 2019-05-03 01:05:04 -0700 | [diff] [blame] | 84 | "updater.cpp", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 85 | ], |
| 86 | |
Tianjie Xu | 76e165d | 2019-05-30 10:24:47 -0700 | [diff] [blame] | 87 | target: { |
| 88 | darwin: { |
| 89 | enabled: false, |
| 90 | }, |
| 91 | }, |
| 92 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 93 | export_include_dirs: [ |
| 94 | "include", |
| 95 | ], |
| 96 | } |
| 97 | |
| 98 | cc_library_static { |
| 99 | name: "libupdater_device", |
| 100 | |
| 101 | defaults: [ |
| 102 | "recovery_defaults", |
| 103 | "libupdater_defaults", |
| 104 | "libupdater_device_defaults", |
| 105 | ], |
| 106 | |
| 107 | srcs: [ |
| 108 | "dynamic_partitions.cpp", |
Tianjie Xu | 1536db8 | 2019-05-14 10:54:43 -0700 | [diff] [blame] | 109 | "updater_runtime.cpp", |
Tianjie Xu | d118833 | 2019-05-24 16:08:45 -0700 | [diff] [blame] | 110 | "updater_runtime_dynamic_partitions.cpp", |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 111 | ], |
| 112 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 113 | static_libs: [ |
| 114 | "libupdater_core", |
| 115 | ], |
| 116 | |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 117 | include_dirs: [ |
| 118 | "external/e2fsprogs/misc", |
| 119 | ], |
| 120 | |
| 121 | export_include_dirs: [ |
| 122 | "include", |
| 123 | ], |
| 124 | } |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 125 | |
| 126 | cc_library_host_static { |
| 127 | name: "libupdater_host", |
| 128 | |
| 129 | defaults: [ |
| 130 | "recovery_defaults", |
| 131 | "libupdater_defaults", |
| 132 | ], |
| 133 | |
| 134 | srcs: [ |
Tianjie Xu | 74b0f7c | 2019-05-22 13:59:57 -0700 | [diff] [blame] | 135 | "build_info.cpp", |
Tianjie Xu | d118833 | 2019-05-24 16:08:45 -0700 | [diff] [blame] | 136 | "dynamic_partitions.cpp", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 137 | "simulator_runtime.cpp", |
| 138 | "target_files.cpp", |
| 139 | ], |
| 140 | |
| 141 | static_libs: [ |
| 142 | "libupdater_core", |
| 143 | "libfstab", |
Tianjie Xu | 74b0f7c | 2019-05-22 13:59:57 -0700 | [diff] [blame] | 144 | "libc++fs", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 145 | ], |
| 146 | |
Tianjie Xu | 76e165d | 2019-05-30 10:24:47 -0700 | [diff] [blame] | 147 | target: { |
| 148 | darwin: { |
| 149 | enabled: false, |
| 150 | }, |
| 151 | }, |
| 152 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 153 | export_include_dirs: [ |
| 154 | "include", |
| 155 | ], |
| 156 | } |