blob: 0cfce92a98078415335d1fd4afd79a351b58bef0 [file] [log] [blame]
Bob Badour76f9b092021-09-08 14:01:45 -07001package {
2 default_applicable_licenses: ["build_blueprint_license"],
3}
4
5// Added automatically by a large-scale-change that took the approach of
6// 'apply every license found to every target'. While this makes sure we respect
7// every license restriction, it may not be entirely correct.
8//
9// e.g. GPL in an MIT project might only apply to the contrib/ directory.
10//
11// Please consider splitting the single license below into multiple licenses,
12// taking care not to lose any license_kind information, and overriding the
13// default license using the 'licenses: [...]' property on targets as needed.
14//
15// For unused files, consider creating a 'fileGroup' with "//visibility:private"
16// to attach the license to, and including a comment whether the files may be
17// used in the current project.
18// See: http://go/android-license-faq
19license {
20 name: "build_blueprint_license",
21 visibility: [":__subpackages__"],
22 license_kinds: [
23 "SPDX-license-identifier-Apache-2.0",
24 "SPDX-license-identifier-BSD",
25 ],
26 license_text: [
27 "LICENSE",
28 ],
29}
30
Colin Cross4a0fe082017-10-19 15:30:06 -070031bootstrap_go_package {
32 name: "blueprint",
33 deps: [
Chris Parsons18ebb232022-03-25 00:56:02 -040034 "blueprint-metrics",
Colin Crossf5bd8282015-01-23 14:24:17 -080035 "blueprint-parser",
Michael Beardsworth1ec44532015-03-31 20:39:02 -070036 "blueprint-pathtools",
Colin Crossf5bd8282015-01-23 14:24:17 -080037 "blueprint-proptools",
38 ],
Colin Cross4a0fe082017-10-19 15:30:06 -070039 pkgPath: "github.com/google/blueprint",
40 srcs: [
Colin Crossf5bd8282015-01-23 14:24:17 -080041 "context.go",
Yu Liubd160372024-06-11 00:09:41 +000042 "incremental.go",
Steven Morelandd457f112023-03-31 20:49:09 +000043 "levenshtein.go",
Colin Cross127d2ea2016-11-01 11:10:51 -070044 "glob.go",
Colin Crossf5bd8282015-01-23 14:24:17 -080045 "live_tracker.go",
46 "mangle.go",
47 "module_ctx.go",
Jeff Gastond70bf752017-11-10 15:12:08 -080048 "name_interface.go",
Colin Crossf5bd8282015-01-23 14:24:17 -080049 "ninja_defs.go",
50 "ninja_strings.go",
51 "ninja_writer.go",
52 "package_ctx.go",
Colin Cross2da84922020-07-02 10:08:12 -070053 "provider.go",
Colin Crossf5bd8282015-01-23 14:24:17 -080054 "scope.go",
55 "singleton_ctx.go",
Cole Faust7add6212024-01-25 14:45:22 -080056 "source_file_provider.go",
Colin Cross95b36272024-04-12 14:48:34 -070057 "transition.go",
Colin Crossf5bd8282015-01-23 14:24:17 -080058 ],
Colin Cross4a0fe082017-10-19 15:30:06 -070059 testSrcs: [
Dan Willemsen87ba2942015-06-23 17:21:00 -070060 "context_test.go",
Steven Morelandd457f112023-03-31 20:49:09 +000061 "levenshtein_test.go",
Colin Cross54cb95a2018-02-23 11:09:18 -080062 "glob_test.go",
Colin Crossf7beb892019-11-13 20:11:14 -080063 "module_ctx_test.go",
Dan Willemsen87ba2942015-06-23 17:21:00 -070064 "ninja_strings_test.go",
65 "ninja_writer_test.go",
Colin Cross2da84922020-07-02 10:08:12 -070066 "provider_test.go",
Dan Willemsen87ba2942015-06-23 17:21:00 -070067 "splice_modules_test.go",
Colin Cross95b36272024-04-12 14:48:34 -070068 "transition_test.go",
Colin Cross4a0fe082017-10-19 15:30:06 -070069 "visit_test.go",
Dan Willemsen87ba2942015-06-23 17:21:00 -070070 ],
Colin Cross4a0fe082017-10-19 15:30:06 -070071}
Jamie Gennis1bc967e2014-05-27 16:34:41 -070072
Colin Cross4a0fe082017-10-19 15:30:06 -070073bootstrap_go_package {
74 name: "blueprint-parser",
75 pkgPath: "github.com/google/blueprint/parser",
76 srcs: [
Colin Crosse32cc802016-06-07 12:28:16 -070077 "parser/ast.go",
Colin Crossf5bd8282015-01-23 14:24:17 -080078 "parser/modify.go",
79 "parser/parser.go",
80 "parser/printer.go",
81 "parser/sort.go",
82 ],
Colin Cross4a0fe082017-10-19 15:30:06 -070083 testSrcs: [
Colin Cross957b39c2018-03-21 18:10:01 -070084 "parser/modify_test.go",
Dan Willemsen87ba2942015-06-23 17:21:00 -070085 "parser/parser_test.go",
86 "parser/printer_test.go",
Lukacs T. Berkieef56852021-09-02 11:34:06 +020087 "parser/sort_test.go",
Dan Willemsen87ba2942015-06-23 17:21:00 -070088 ],
Colin Cross4a0fe082017-10-19 15:30:06 -070089}
Jamie Gennis1bc967e2014-05-27 16:34:41 -070090
Colin Cross4a0fe082017-10-19 15:30:06 -070091bootstrap_go_package {
92 name: "blueprint-deptools",
93 pkgPath: "github.com/google/blueprint/deptools",
94 srcs: ["deptools/depfile.go"],
95}
Jamie Gennisfbb27fe2014-10-14 04:30:17 -040096
Colin Cross4a0fe082017-10-19 15:30:06 -070097bootstrap_go_package {
98 name: "blueprint-pathtools",
99 pkgPath: "github.com/google/blueprint/pathtools",
100 deps: [
Colin Cross127d2ea2016-11-01 11:10:51 -0700101 "blueprint-deptools",
102 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700103 srcs: [
Colin Crossf5bd8282015-01-23 14:24:17 -0800104 "pathtools/lists.go",
Colin Crossb519a7e2017-02-01 13:21:35 -0800105 "pathtools/fs.go",
Colin Crossf5bd8282015-01-23 14:24:17 -0800106 "pathtools/glob.go",
107 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700108 testSrcs: [
Colin Crossc64f2642018-09-20 21:48:44 -0700109 "pathtools/fs_test.go",
Dan Willemsen87ba2942015-06-23 17:21:00 -0700110 "pathtools/glob_test.go",
ThiƩbaud Weksteen8ec69072021-02-15 18:54:26 +0000111 "pathtools/lists_test.go",
Dan Willemsen87ba2942015-06-23 17:21:00 -0700112 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700113}
Jamie Gennisb9314562014-06-06 14:37:07 -0700114
Colin Cross4a0fe082017-10-19 15:30:06 -0700115bootstrap_go_package {
116 name: "blueprint-proptools",
117 pkgPath: "github.com/google/blueprint/proptools",
Colin Crossf27c5e42020-01-02 09:37:49 -0800118 deps: [
119 "blueprint-parser",
Cole Faustad00dd52024-05-21 14:20:33 -0700120 "blueprint-optional",
Colin Crossf27c5e42020-01-02 09:37:49 -0800121 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700122 srcs: [
Colin Cross81695002015-10-30 13:19:14 -0700123 "proptools/clone.go",
Cole Faust6437d4e2024-02-01 17:44:27 -0800124 "proptools/configurable.go",
Colin Cross41ca49f2016-09-29 13:19:34 -0700125 "proptools/escape.go",
Colin Cross0bc7e072015-10-27 18:15:15 -0700126 "proptools/extend.go",
Colin Cross19078362019-09-25 11:23:13 -0700127 "proptools/filter.go",
Cole Faust7add6212024-01-25 14:45:22 -0800128 "proptools/hash_provider.go",
Colin Cross0bc7e072015-10-27 18:15:15 -0700129 "proptools/proptools.go",
Colin Crossa4f6a3b2019-03-05 16:34:45 -0800130 "proptools/tag.go",
Colin Crosse4b0d352015-11-02 14:58:10 -0800131 "proptools/typeequal.go",
Colin Crossf27c5e42020-01-02 09:37:49 -0800132 "proptools/unpack.go",
Yu Liu82e44472024-05-15 19:16:55 +0000133 "proptools/utils.go",
Colin Cross0bc7e072015-10-27 18:15:15 -0700134 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700135 testSrcs: [
Colin Crossf72ef502015-10-30 11:42:57 -0700136 "proptools/clone_test.go",
Cole Faust0c63da92024-08-27 14:54:04 -0700137 "proptools/configurable_test.go",
Colin Cross41ca49f2016-09-29 13:19:34 -0700138 "proptools/escape_test.go",
Colin Cross0bc7e072015-10-27 18:15:15 -0700139 "proptools/extend_test.go",
Colin Cross19078362019-09-25 11:23:13 -0700140 "proptools/filter_test.go",
Cole Faust7add6212024-01-25 14:45:22 -0800141 "proptools/hash_provider_test.go",
Colin Crossa4f6a3b2019-03-05 16:34:45 -0800142 "proptools/tag_test.go",
Colin Crosse4b0d352015-11-02 14:58:10 -0800143 "proptools/typeequal_test.go",
Colin Crossf27c5e42020-01-02 09:37:49 -0800144 "proptools/unpack_test.go",
Colin Cross0bc7e072015-10-27 18:15:15 -0700145 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700146}
Jamie Gennisb9cbdae2014-10-02 18:36:13 -0700147
Colin Cross4a0fe082017-10-19 15:30:06 -0700148bootstrap_go_package {
Cole Faustad00dd52024-05-21 14:20:33 -0700149 name: "blueprint-optional",
150 pkgPath: "github.com/google/blueprint/optional",
151 srcs: [
152 "optional/optional.go",
153 ],
154}
155
156bootstrap_go_package {
Colin Cross4a0fe082017-10-19 15:30:06 -0700157 name: "blueprint-bootstrap",
158 deps: [
Colin Crossf5bd8282015-01-23 14:24:17 -0800159 "blueprint",
160 "blueprint-deptools",
161 "blueprint-pathtools",
Colin Cross4572edd2015-05-13 14:36:24 -0700162 "blueprint-bootstrap-bpdoc",
Colin Crossf5bd8282015-01-23 14:24:17 -0800163 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700164 pkgPath: "github.com/google/blueprint/bootstrap",
165 srcs: [
Colin Crossf5bd8282015-01-23 14:24:17 -0800166 "bootstrap/bootstrap.go",
Colin Crossf5bd8282015-01-23 14:24:17 -0800167 "bootstrap/command.go",
168 "bootstrap/config.go",
Colin Cross4572edd2015-05-13 14:36:24 -0700169 "bootstrap/writedocs.go",
170 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700171}
Colin Cross4572edd2015-05-13 14:36:24 -0700172
Colin Cross4a0fe082017-10-19 15:30:06 -0700173bootstrap_go_package {
174 name: "blueprint-bootstrap-bpdoc",
175 deps: [
Colin Cross4572edd2015-05-13 14:36:24 -0700176 "blueprint",
177 "blueprint-proptools",
178 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700179 pkgPath: "github.com/google/blueprint/bootstrap/bpdoc",
180 srcs: [
Colin Cross4572edd2015-05-13 14:36:24 -0700181 "bootstrap/bpdoc/bpdoc.go",
Jaewoong Jung781f6b22019-02-06 16:20:17 -0800182 "bootstrap/bpdoc/properties.go",
183 "bootstrap/bpdoc/reader.go",
184 ],
185 testSrcs: [
Jaewoong Jungbd0f6c32019-05-28 13:16:20 -0700186 "bootstrap/bpdoc/bpdoc_test.go",
187 "bootstrap/bpdoc/properties_test.go",
Jaewoong Jung781f6b22019-02-06 16:20:17 -0800188 "bootstrap/bpdoc/reader_test.go",
Colin Crossf5bd8282015-01-23 14:24:17 -0800189 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700190}
Jamie Gennis1bc967e2014-05-27 16:34:41 -0700191
Lukacs T. Berkiceb3c432021-09-01 08:58:07 +0200192blueprint_go_binary {
Colin Cross4a0fe082017-10-19 15:30:06 -0700193 name: "bpfmt",
194 deps: ["blueprint-parser"],
195 srcs: ["bpfmt/bpfmt.go"],
196}
Colin Cross41c397a2015-01-12 17:43:04 -0800197
Colin Cross4a0fe082017-10-19 15:30:06 -0700198blueprint_go_binary {
199 name: "bpmodify",
Chris Parsonsc2753f92022-08-02 15:24:37 -0400200 deps: [
201 "blueprint-parser",
202 "blueprint-proptools",
203 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700204 srcs: ["bpmodify/bpmodify.go"],
Chris Parsonsc2753f92022-08-02 15:24:37 -0400205 testSrcs: ["bpmodify/bpmodify_test.go"],
Colin Cross4a0fe082017-10-19 15:30:06 -0700206}
Dan Willemsen87ba2942015-06-23 17:21:00 -0700207
Lukacs T. Berkiceb3c432021-09-01 08:58:07 +0200208blueprint_go_binary {
Colin Cross4a0fe082017-10-19 15:30:06 -0700209 name: "gotestmain",
210 srcs: ["gotestmain/gotestmain.go"],
211}
Dan Willemsen91a657e2015-07-22 17:05:59 -0700212
Colin Cross5f303b92017-07-12 17:04:33 -0700213// gotestmain tests can't be on the gotestmain module because it is an implicit dependency of tests.
214// Put the tests in their own package and make it a dependency of minibp to make sure they run.
Colin Cross4a0fe082017-10-19 15:30:06 -0700215bootstrap_go_package {
216 name: "gotestmain-tests",
217 pkgPath: "github.com/google/blueprint/gotestmain",
218 srcs: [
Colin Cross5f303b92017-07-12 17:04:33 -0700219 "gotestmain/dummy.go",
220 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700221 testSrcs: [
Colin Cross5f303b92017-07-12 17:04:33 -0700222 "gotestmain/testmain_test.go",
223 ],
Colin Cross4a0fe082017-10-19 15:30:06 -0700224}
Colin Cross5f303b92017-07-12 17:04:33 -0700225
Lukacs T. Berkiceb3c432021-09-01 08:58:07 +0200226blueprint_go_binary {
Colin Cross4a0fe082017-10-19 15:30:06 -0700227 name: "gotestrunner",
228 srcs: ["gotestrunner/gotestrunner.go"],
229}
Dan Willemsenc7697ce2015-09-17 20:59:51 -0700230
Lukacs T. Berkiceb3c432021-09-01 08:58:07 +0200231blueprint_go_binary {
Colin Cross4a0fe082017-10-19 15:30:06 -0700232 name: "loadplugins",
233 srcs: ["loadplugins/loadplugins.go"],
Dan Willemsenfdeb7242015-07-24 16:53:27 -0700234}
Dan Willemsen1e723212017-07-18 19:37:37 -0700235
236blueprint_go_binary {
237 name: "microfactory",
Dan Willemsenff092862017-08-08 13:14:40 -0700238 deps: ["blueprint-microfactory"],
239 srcs: ["microfactory/main/main.go"],
240}
241
242bootstrap_go_package {
243 name: "blueprint-microfactory",
244 pkgPath: "github.com/google/blueprint/microfactory",
Dan Willemsen1e723212017-07-18 19:37:37 -0700245 srcs: ["microfactory/microfactory.go"],
246 testSrcs: ["microfactory/microfactory_test.go"],
247}