1package { 2 default_applicable_licenses: ["external_iw_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// 19// large-scale-change included anything that looked like it might be a license 20// text as a license_text. e.g. LICENSE, NOTICE, COPYING etc. 21// 22// Please consider removing redundant or irrelevant files from 'license_text:'. 23// See: http://go/android-license-faq 24license { 25 name: "external_iw_license", 26 visibility: [":__subpackages__"], 27 license_kinds: [ 28 "SPDX-license-identifier-BSD", 29 "SPDX-license-identifier-ISC", 30 ], 31 license_text: [ 32 "COPYING", 33 "NOTICE", 34 ], 35} 36 37genrule { 38 name: "iw_version", 39 cmd: "echo '#include \"iw.h\"' >$(out) && " + 40 "echo \"const char iw_version[] = $$(grep ^VERSION $(location version.sh) | sed \"s/VERSION=//\");\" >>$(out)", 41 srcs: ["version.sh"], 42 out: ["version.c"], 43} 44 45cc_defaults { 46 name: "iw_common", 47 48 srcs: [ 49 "iw.c", 50 "genl.c", 51 "event.c", 52 "info.c", 53 "phy.c", 54 "interface.c", 55 "ibss.c", 56 "station.c", 57 "survey.c", 58 "util.c", 59 "ocb.c", 60 "mesh.c", 61 "mpath.c", 62 "mpp.c", 63 "scan.c", 64 "reg.c", 65 "reason.c", 66 "status.c", 67 "connect.c", 68 "link.c", 69 "offch.c", 70 "ps.c", 71 "cqm.c", 72 "bitrate.c", 73 "wowlan.c", 74 "coalesce.c", 75 "roc.c", 76 "p2p.c", 77 "vendor.c", 78 "sections.c", 79 "ap.c", 80 "bloom.c", 81 "ftm.c", 82 "measurements.c", 83 "mgmt.c", 84 "nan.c", 85 "sar.c", 86 "sha256.c", 87 88 ":iw_version", 89 ], 90 91 cflags: [ 92 "-fno-strict-aliasing", 93 "-D_GNU_SOURCE", 94 "-DCONFIG_LIBNL20", 95 96 // Silence some warnings for now. Needs to be fixed upstream. b/26105799 97 "-Wno-unused-parameter", 98 "-Wno-sign-compare", 99 "-Wno-format", 100 "-Wno-absolute-value", 101 "-Wno-enum-conversion", 102 "-Werror", 103 ], 104 105 ldflags: ["-Wl,--no-gc-sections"], 106 shared_libs: ["libnl"], 107} 108 109cc_binary { 110 name: "iw", 111 112 defaults: ["iw_common"], 113} 114 115cc_binary { 116 name: "iw_vendor", 117 stem: "iw", 118 vendor: true, 119 defaults: ["iw_common"], 120} 121