blob: 1d965cce262fb3e786aaa10e7c30d5048b304cc7 [file] [log] [blame]
xunchang24788852019-03-22 16:08:52 -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
Bob Badour29be3f62021-02-12 18:00:57 -080015package {
16 // See: http://go/android-license-faq
17 // A large-scale-change added 'default_applicable_licenses' to import
18 // all of the 'license_kinds' from "bootable_recovery_license"
19 // to get the below license kinds:
20 // SPDX-license-identifier-Apache-2.0
21 default_applicable_licenses: ["bootable_recovery_license"],
22}
23
xunchang24788852019-03-22 16:08:52 -070024cc_defaults {
25 name: "libinstall_defaults",
26
27 defaults: [
28 "recovery_defaults",
Kelvin Zhange6312252021-05-14 17:15:50 -040029 "libspl_check_defaults",
xunchang24788852019-03-22 16:08:52 -070030 ],
31
bigbiff673c7ae2020-12-02 19:44:56 -050032 cflags: [
33 //"-DRECOVERY_API_VERSION=3"
xunchang95d67322019-04-05 16:16:07 -070034 ],
35
xunchang24788852019-03-22 16:08:52 -070036 shared_libs: [
37 "libbase",
38 "libbootloader_message",
39 "libcrypto",
40 "libext4_utils",
41 "libfs_mgr",
42 "libfusesideload",
43 "libhidl-gen-utils",
44 "libhidlbase",
xunchang24788852019-03-22 16:08:52 -070045 "liblog",
46 "libselinux",
47 "libtinyxml2",
48 "libutils",
49 "libz",
50 "libziparchive",
51 ],
52
53 static_libs: [
Tao Baoe3f09a72019-10-01 11:55:36 -070054 "librecovery_utils",
xunchang24788852019-03-22 16:08:52 -070055 "libotautil",
David Anderson89d2d052019-10-15 13:22:20 -070056 "libsnapshot_nobinder",
Kelvin Zhange6312252021-05-14 17:15:50 -040057 "ota_metadata_proto_cc",
bigbiffe1981e52021-11-21 14:35:27 -050058 "update_metadata-protos",
xunchang24788852019-03-22 16:08:52 -070059
60 // external dependencies
xunchang24788852019-03-22 16:08:52 -070061 "libvintf",
xunchang24788852019-03-22 16:08:52 -070062 ],
63}
64
Kelvin Zhange6312252021-05-14 17:15:50 -040065cc_test_host {
66 name: "libinstall_host_unittests",
67 defaults: [
68 "libspl_check_defaults"
69 ],
70 srcs: [
71 "spl_check_unittests.cpp",
72 ],
73 static_libs: [
74 "libspl_check",
75 ],
76}
77
78cc_defaults {
79 name: "libspl_check_defaults",
80 static_libs: [
81 "libbase",
82 "ota_metadata_proto_cc",
83 "liblog",
84 "libziparchive",
85 "libz",
86 "libprotobuf-cpp-lite",
bigbiffe1981e52021-11-21 14:35:27 -050087 "update_metadata-protos",
Kelvin Zhange6312252021-05-14 17:15:50 -040088 ],
89}
90
91cc_library_static {
92 name: "libspl_check",
93 recovery_available: true,
94 host_supported: true,
95 defaults: [
96 "libspl_check_defaults",
97 ],
98 srcs: ["spl_check.cpp"],
99 export_include_dirs: [
100 "include",
101 ],
102}
103
Tao Bao2f8afba2019-04-08 11:26:11 -0700104cc_library_static {
xunchang24788852019-03-22 16:08:52 -0700105 name: "libinstall",
106 recovery_available: true,
107
108 defaults: [
109 "libinstall_defaults",
110 ],
111
112 srcs: [
113 "adb_install.cpp",
114 "asn1_decoder.cpp",
Tianjie Xuf6158eb2019-06-11 16:09:07 -0700115 "fuse_install.cpp",
xunchang24788852019-03-22 16:08:52 -0700116 "install.cpp",
117 "package.cpp",
David Anderson89d2d052019-10-15 13:22:20 -0700118 "snapshot_utils.cpp",
xunchang24788852019-03-22 16:08:52 -0700119 "verifier.cpp",
xunchang388d2532019-04-12 16:22:15 -0700120 "wipe_data.cpp",
Tao Bao7f19d102019-04-26 22:56:56 -0700121 "wipe_device.cpp",
Kelvin Zhange6312252021-05-14 17:15:50 -0400122 "spl_check.cpp",
xunchang24788852019-03-22 16:08:52 -0700123 ],
124
Tao Bao3305d482019-09-26 00:02:29 -0700125 header_libs: [
126 "libminadbd_headers",
xunchang24788852019-03-22 16:08:52 -0700127 ],
128
129 shared_libs: [
130 "librecovery_ui",
131 ],
132
133 export_include_dirs: [
134 "include",
135 ],
136
137 export_shared_lib_headers: [
138 "librecovery_ui",
139 ],
140}