blob: 7ad70eef67100f4e066880d1d55efcef146ca927 [file] [log] [blame]
Greg Hartmanbff7e632017-09-29 11:32:08 -07001//
2// Copyright (C) 2017 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15
Bob Badour133979c2021-03-11 19:30:34 -080016package {
17 default_applicable_licenses: ["device_google_cuttlefish_license"],
18}
19
20// Added automatically by a large-scale-change that took the approach of
21// 'apply every license found to every target'. While this makes sure we respect
22// every license restriction, it may not be entirely correct.
23//
24// e.g. GPL in an MIT project might only apply to the contrib/ directory.
25//
26// Please consider splitting the single license below into multiple licenses,
27// taking care not to lose any license_kind information, and overriding the
28// default license using the 'licenses: [...]' property on targets as needed.
29//
30// For unused files, consider creating a 'fileGroup' with "//visibility:private"
31// to attach the license to, and including a comment whether the files may be
32// used in the current project.
33// See: http://go/android-license-faq
34license {
35 name: "device_google_cuttlefish_license",
36 visibility: [":__subpackages__"],
37 license_kinds: [
38 "SPDX-license-identifier-Apache-2.0",
39 "SPDX-license-identifier-MIT",
40 ],
41 // large-scale-change unable to identify any license_text files
42}
43
Greg Hartmanbff7e632017-09-29 11:32:08 -070044cc_library_headers {
Greg Hartmana4ff2482017-10-03 16:35:00 -070045 name: "cuttlefish_common_headers",
Justin Yun6ca23bd2020-12-11 17:16:37 +090046 vendor_available: true,
47 product_available: true,
Ram Muthiah792e2ad2019-04-19 11:19:46 -070048 export_include_dirs: ["."],
49 host_supported: true,
Jiyong Parkb86c2f72021-01-05 16:55:32 +090050 apex_available: [
51 "//apex_available:platform",
52 "com.android.virt",
53 ],
Ram Muthiah792e2ad2019-04-19 11:19:46 -070054}
55
Greg Hartmanbff7e632017-09-29 11:32:08 -070056cc_defaults {
Greg Hartmance872ef2017-12-04 22:51:47 -080057 name: "cuttlefish_base",
Tomasz Wiszkowski55d53ff2017-12-04 15:39:57 -080058 gnu_extensions: false,
59 header_libs: [
60 "cuttlefish_common_headers",
Tomasz Wiszkowski55d53ff2017-12-04 15:39:57 -080061 ],
Tomasz Wiszkowski55d53ff2017-12-04 15:39:57 -080062 target: {
Ryan Haining508c8082018-03-13 11:26:19 -070063 host: {
Tomasz Wiszkowski55d53ff2017-12-04 15:39:57 -080064 host_ldlibs: ["-lrt"],
65 cflags: ["-DCUTTLEFISH_HOST"],
Ryan Haining508c8082018-03-13 11:26:19 -070066 compile_multilib: "64",
Ryan Haininged1fe922018-03-13 17:43:30 +000067 },
68 // We don't need Darwin host-side builds
69 darwin: {
70 enabled: false,
Greg Hartmana4ff2482017-10-03 16:35:00 -070071 },
Greg Hartmanbff7e632017-09-29 11:32:08 -070072 },
Cody Schuffelen88b82d52019-05-29 14:16:03 -070073 cflags: ["-Werror", "-Wall", "-D_FILE_OFFSET_BITS=64"],
Jiyong Parkb86c2f72021-01-05 16:55:32 +090074 apex_available: [
75 "//apex_available:platform",
76 "com.android.virt",
77 ],
Greg Hartmana4ff2482017-10-03 16:35:00 -070078}
79
Jiyong Park58c326b2021-01-05 16:52:58 +090080// Defaults for cuttlefish modules that are available only in the guest OS (i.e. cuttlefish running
81// in a guest VM).
Ram Muthiah792e2ad2019-04-19 11:19:46 -070082cc_defaults {
Greg Hartmane9adb542018-05-09 13:12:51 -070083 name: "cuttlefish_guest_only",
Justin Yun6ca23bd2020-12-11 17:16:37 +090084 vendor: true,
Greg Hartmane9adb542018-05-09 13:12:51 -070085 defaults: ["cuttlefish_base"],
86}
87
Jiyong Park58c326b2021-01-05 16:52:58 +090088// Same as cuttlefish_guest_only, but modules are placed in /product partition.
Greg Hartmane9adb542018-05-09 13:12:51 -070089cc_defaults {
Jiyong Park58c326b2021-01-05 16:52:58 +090090 name: "cuttlefish_guest_product_only",
91 product_specific: true,
Greg Hartmance872ef2017-12-04 22:51:47 -080092 defaults: ["cuttlefish_base"],
93}
94
Jiyong Park58c326b2021-01-05 16:52:58 +090095// Defaults for cuttlefish modules that are available only in the host-side OS. Here "host" includes
96// both (1) non-Android OS like gLinux or Ubuntu, and (2) Android OS that is capable of running
97// guest VM(s) in it. Note that, in the context of the Android build systm - Soong - (1) is called
98// as "host" and (2) is called as "target". But here, the term "host" is in the context of VMs. If a
99// module is for the host-side VM (either Android or non-Android), "cuttlefish_host" shall be used.
100cc_defaults {
101 name: "cuttlefish_host",
102 host_supported: true, // this "host" means (1)
103 device_supported: true, // this is for (2)
104 vendor_available: true,
105 defaults: ["cuttlefish_base"],
106}
107
108// Same as "cuttlefish_host", but only for non-Android OS.
109cc_defaults {
110 name: "cuttlefish_buildhost_only",
Greg Hartmance872ef2017-12-04 22:51:47 -0800111 host_supported: true,
Jiyong Park58c326b2021-01-05 16:52:58 +0900112 device_supported: false,
Greg Hartmance872ef2017-12-04 22:51:47 -0800113 defaults: ["cuttlefish_base"],
114}
Ram Muthiah0f7fc062019-12-10 15:48:14 -0800115
116cc_defaults {
117 name: "cuttlefish_recovery_available",
118 recovery_available : true
119}
120
121cc_defaults {
122 name: "enabled_on_p_and_later",
123 enabled: true
124}
125
126cc_defaults {
127 name: "enabled_on_q_and_later",
128 enabled: true
129}
130
131cc_defaults {
132 name: "enabled_on_q_internal_and_later",
133 enabled: true
134}
135
136cc_defaults {
Ram Muthiah0f7fc062019-12-10 15:48:14 -0800137 name: "cuttlefish_libicuuc",
Alistair Delva8cd279f2020-09-03 08:35:39 -0700138 target: {
139 host: {
140 shared_libs: [
141 "libicuuc",
142 ],
143 },
144 },
Ram Muthiah0f7fc062019-12-10 15:48:14 -0800145}
146
147cc_defaults {
148 name: "cuttlefish_health_storage",
149 defaults: ["enabled_on_q_and_later"],
Ram Muthiah0f7fc062019-12-10 15:48:14 -0800150}
151
152java_test_host {
153 name: "tombstone_transmit_tests",
154
155 libs: ["tradefed"],
156
157 srcs: ["tests/src/**/TombstoneTransmitTest.java"],
158
159 test_config: "tests/tombstone-transmit-tests.xml",
160
161 test_suites: ["general-tests"],
162}
Jiyong Park4613c422021-02-01 22:14:13 +0900163
164filegroup {
165 name: "cf_dtb",
166 srcs: ["dtb.img"],
167}