blob: 149ac7576f8e06053eeec67cbc771434407afc64 [file] [log] [blame]
Dan Willemsenb9548b72018-10-31 10:17:02 -07001// Copyright 2016 The Android Open Source Project
Bob Badour88ad0042021-02-12 15:22:26 -08002package {
3 default_applicable_licenses: ["external_dtc_license"],
4}
5
6// Added automatically by a large-scale-change that took the approach of
7// 'apply every license found to every target'. While this makes sure we respect
8// every license restriction, it may not be entirely correct.
9//
10// e.g. GPL in an MIT project might only apply to the contrib/ directory.
11//
12// Please consider splitting the single license below into multiple licenses,
13// taking care not to lose any license_kind information, and overriding the
14// default license using the 'licenses: [...]' property on targets as needed.
15//
16// For unused files, consider creating a 'fileGroup' with "//visibility:private"
17// to attach the license to, and including a comment whether the files may be
18// used in the current project.
19//
20// large-scale-change included anything that looked like it might be a license
21// text as a license_text. e.g. LICENSE, NOTICE, COPYING etc.
22//
23// Please consider removing redundant or irrelevant files from 'license_text:'.
24// See: http://go/android-license-faq
25license {
26 name: "external_dtc_license",
27 visibility: [":__subpackages__"],
28 license_kinds: [
29 "SPDX-license-identifier-BSD",
30 "SPDX-license-identifier-BSD-2-Clause",
31 "SPDX-license-identifier-GPL",
32 "SPDX-license-identifier-GPL-2.0",
33 "SPDX-license-identifier-ISC",
34 "SPDX-license-identifier-LGPL",
35 "SPDX-license-identifier-LGPL-2.1",
36 ],
37 license_text: [
38 "NOTICE",
39 "README.license",
40 ],
41}
42
Martin Liu38bd6fa2019-03-19 15:37:35 +080043cc_defaults {
44 name: "dt_defaults",
Dan Willemsenb9548b72018-10-31 10:17:02 -070045 cflags: [
46 "-Wall",
47 "-Werror",
48 "-Wno-sign-compare",
49 "-Wno-missing-field-initializers",
50 "-Wno-unused-parameter",
Steve Muckleb734cfd2020-07-08 17:22:37 -070051 "-DNO_YAML"
Dan Willemsenb9548b72018-10-31 10:17:02 -070052 ],
Martin Liu38bd6fa2019-03-19 15:37:35 +080053
Alistair Delva83534bb2020-07-31 10:40:06 -070054 shared_libs: ["libfdt"],
Martin Liu38bd6fa2019-03-19 15:37:35 +080055
56 stl: "none",
57 dist: {
58 targets: [
59 "dist_files",
60 ],
61 dir: "dtc",
62 },
63}
64
65cc_binary_host {
66 name: "dtc",
67 defaults: ["dt_defaults"],
Dan Willemsenb9548b72018-10-31 10:17:02 -070068 srcs: [
69 "checks.c",
70 "data.c",
71 "dtc.c",
72 "dtc-lexer.l",
73 "dtc-parser.y",
74 "flattree.c",
75 "fstree.c",
76 "livetree.c",
77 "srcpos.c",
78 "treesource.c",
79 "util.c",
80 ],
Martin Liu38bd6fa2019-03-19 15:37:35 +080081}
Dan Willemsenb9548b72018-10-31 10:17:02 -070082
Martin Liu38bd6fa2019-03-19 15:37:35 +080083cc_binary_host {
84 name: "fdtget",
85 defaults: ["dt_defaults"],
86 srcs: [
87 "fdtget.c",
88 "util.c",
89 ],
Dan Willemsenb9548b72018-10-31 10:17:02 -070090}