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", |
| 44 | "libcrypto", |
| 45 | "libcrypto_utils", |
| 46 | "libcutils", |
| 47 | "libutils", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 48 | ], |
| 49 | } |
| 50 | |
| 51 | cc_defaults { |
| 52 | name: "libupdater_device_defaults", |
| 53 | |
| 54 | static_libs: [ |
| 55 | "libfs_mgr", |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 56 | "libtune2fs", |
| 57 | |
| 58 | "libext2_com_err", |
| 59 | "libext2_blkid", |
| 60 | "libext2_quota", |
| 61 | "libext2_uuid", |
| 62 | "libext2_e2p", |
| 63 | "libext2fs", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 64 | ] |
Tao Bao | 673bb6f | 2018-08-03 20:56:25 -0700 | [diff] [blame] | 65 | } |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 66 | |
| 67 | cc_library_static { |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 68 | name: "libupdater_core", |
| 69 | |
| 70 | host_supported: true, |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 71 | |
| 72 | defaults: [ |
| 73 | "recovery_defaults", |
| 74 | "libupdater_defaults", |
| 75 | ], |
| 76 | |
| 77 | srcs: [ |
| 78 | "blockimg.cpp", |
| 79 | "commands.cpp", |
| 80 | "install.cpp", |
Tianjie Xu | 58d5912 | 2019-05-03 01:05:04 -0700 | [diff] [blame] | 81 | "updater.cpp", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 82 | ], |
| 83 | |
Tianjie Xu | 76e165d | 2019-05-30 10:24:47 -0700 | [diff] [blame] | 84 | target: { |
| 85 | darwin: { |
| 86 | enabled: false, |
| 87 | }, |
| 88 | }, |
| 89 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 90 | export_include_dirs: [ |
| 91 | "include", |
| 92 | ], |
| 93 | } |
| 94 | |
| 95 | cc_library_static { |
| 96 | name: "libupdater_device", |
| 97 | |
| 98 | defaults: [ |
| 99 | "recovery_defaults", |
| 100 | "libupdater_defaults", |
| 101 | "libupdater_device_defaults", |
| 102 | ], |
| 103 | |
| 104 | srcs: [ |
| 105 | "dynamic_partitions.cpp", |
Tianjie Xu | 1536db8 | 2019-05-14 10:54:43 -0700 | [diff] [blame] | 106 | "updater_runtime.cpp", |
Tianjie Xu | d118833 | 2019-05-24 16:08:45 -0700 | [diff] [blame^] | 107 | "updater_runtime_dynamic_partitions.cpp", |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 108 | ], |
| 109 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 110 | static_libs: [ |
| 111 | "libupdater_core", |
| 112 | ], |
| 113 | |
Tao Bao | ef5e38f | 2018-07-24 15:34:39 -0700 | [diff] [blame] | 114 | include_dirs: [ |
| 115 | "external/e2fsprogs/misc", |
| 116 | ], |
| 117 | |
| 118 | export_include_dirs: [ |
| 119 | "include", |
| 120 | ], |
| 121 | } |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 122 | |
| 123 | cc_library_host_static { |
| 124 | name: "libupdater_host", |
| 125 | |
| 126 | defaults: [ |
| 127 | "recovery_defaults", |
| 128 | "libupdater_defaults", |
| 129 | ], |
| 130 | |
| 131 | srcs: [ |
Tianjie Xu | 74b0f7c | 2019-05-22 13:59:57 -0700 | [diff] [blame] | 132 | "build_info.cpp", |
Tianjie Xu | d118833 | 2019-05-24 16:08:45 -0700 | [diff] [blame^] | 133 | "dynamic_partitions.cpp", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 134 | "simulator_runtime.cpp", |
| 135 | "target_files.cpp", |
| 136 | ], |
| 137 | |
| 138 | static_libs: [ |
| 139 | "libupdater_core", |
| 140 | "libfstab", |
Tianjie Xu | 74b0f7c | 2019-05-22 13:59:57 -0700 | [diff] [blame] | 141 | "libc++fs", |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 142 | ], |
| 143 | |
Tianjie Xu | 76e165d | 2019-05-30 10:24:47 -0700 | [diff] [blame] | 144 | target: { |
| 145 | darwin: { |
| 146 | enabled: false, |
| 147 | }, |
| 148 | }, |
| 149 | |
Tianjie Xu | c1a5e26 | 2019-05-22 14:34:12 -0700 | [diff] [blame] | 150 | export_include_dirs: [ |
| 151 | "include", |
| 152 | ], |
| 153 | } |