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", |
Tao Bao | d628cfc | 2019-10-01 12:08:33 -0700 | [diff] [blame] | 84 | "mounts.cpp", |
Tianjie Xu | 58d5912 | 2019-05-03 01:05:04 -0700 | [diff] [blame] | 85 | "updater.cpp", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 86 | ], |
| 87 | |
Tianjie Xu | 76e165d | 2019-05-30 10:24:47 -0700 | [diff] [blame] | 88 | target: { |
| 89 | darwin: { |
| 90 | enabled: false, |
| 91 | }, |
| 92 | }, |
| 93 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 94 | export_include_dirs: [ |
| 95 | "include", |
| 96 | ], |
| 97 | } |
| 98 | |
| 99 | cc_library_static { |
| 100 | name: "libupdater_device", |
| 101 | |
| 102 | defaults: [ |
| 103 | "recovery_defaults", |
| 104 | "libupdater_defaults", |
| 105 | "libupdater_device_defaults", |
| 106 | ], |
| 107 | |
| 108 | srcs: [ |
| 109 | "dynamic_partitions.cpp", |
Tianjie Xu | 1536db8 | 2019-05-14 10:54:43 -0700 | [diff] [blame] | 110 | "updater_runtime.cpp", |
Tianjie Xu | d118833 | 2019-05-24 16:08:45 -0700 | [diff] [blame] | 111 | "updater_runtime_dynamic_partitions.cpp", |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 112 | ], |
| 113 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 114 | static_libs: [ |
| 115 | "libupdater_core", |
| 116 | ], |
| 117 | |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 118 | include_dirs: [ |
| 119 | "external/e2fsprogs/misc", |
| 120 | ], |
| 121 | |
| 122 | export_include_dirs: [ |
| 123 | "include", |
| 124 | ], |
| 125 | } |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 126 | |
| 127 | cc_library_host_static { |
| 128 | name: "libupdater_host", |
| 129 | |
| 130 | defaults: [ |
| 131 | "recovery_defaults", |
| 132 | "libupdater_defaults", |
| 133 | ], |
| 134 | |
| 135 | srcs: [ |
Tianjie Xu | 74b0f7c | 2019-05-22 13:59:57 -0700 | [diff] [blame] | 136 | "build_info.cpp", |
Tianjie Xu | d118833 | 2019-05-24 16:08:45 -0700 | [diff] [blame] | 137 | "dynamic_partitions.cpp", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 138 | "simulator_runtime.cpp", |
| 139 | "target_files.cpp", |
| 140 | ], |
| 141 | |
| 142 | static_libs: [ |
| 143 | "libupdater_core", |
| 144 | "libfstab", |
Tianjie Xu | 74b0f7c | 2019-05-22 13:59:57 -0700 | [diff] [blame] | 145 | "libc++fs", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 146 | ], |
| 147 | |
Tianjie Xu | 76e165d | 2019-05-30 10:24:47 -0700 | [diff] [blame] | 148 | target: { |
| 149 | darwin: { |
| 150 | enabled: false, |
| 151 | }, |
| 152 | }, |
| 153 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 154 | export_include_dirs: [ |
| 155 | "include", |
| 156 | ], |
| 157 | } |