Connor O'Brien | d8c2e9a | 2022-02-14 17:49:38 -0800 | [diff] [blame] | 1 | |
Bob Badour | 2db6b95 | 2022-04-07 21:04:51 -0700 | [diff] [blame] | 2 | package { |
| 3 | default_applicable_licenses: ["external_bpftool_license"], |
| 4 | } |
| 5 | |
| 6 | // See: http://go/android-license-faq |
| 7 | license { |
| 8 | name: "external_bpftool_license", |
| 9 | visibility: [":__subpackages__"], |
| 10 | license_kinds: [ |
| 11 | "SPDX-license-identifier-BSD-2-Clause", |
| 12 | "SPDX-license-identifier-GPL-2.0-only", |
| 13 | ], |
| 14 | license_text: [ |
| 15 | "LICENSE.BSD-2-Clause", |
| 16 | "LICENSE.GPL-2.0", |
| 17 | ], |
| 18 | } |
| 19 | |
Connor O'Brien | d8c2e9a | 2022-02-14 17:49:38 -0800 | [diff] [blame] | 20 | cc_binary_host { |
| 21 | name: "bpftool", |
| 22 | srcs: [ |
| 23 | "src/*.c", |
| 24 | "src/kernel/bpf/disasm.c", |
| 25 | ], |
| 26 | exclude_srcs: [ |
| 27 | "src/jit_disasm.c", |
| 28 | ], |
| 29 | local_include_dirs: [ |
| 30 | "include", |
| 31 | "include/uapi", |
| 32 | "src/kernel/bpf" |
| 33 | ], |
| 34 | static_libs: [ |
| 35 | "libbpf", |
| 36 | "libcap", |
| 37 | "libelf", |
| 38 | "libz", |
| 39 | ], |
| 40 | cflags: [ |
| 41 | "-DBPFTOOL_WITHOUT_SKELETONS", |
| 42 | "-DBPFTOOL_VERSION=\"5.16.0-c446fdacb10d\"", |
| 43 | "-DUSE_LIBCAP", |
| 44 | "-Wno-missing-field-initializers", |
| 45 | "-Wno-pointer-arith", |
| 46 | "-Wno-unused-parameter", |
| 47 | ] |
| 48 | } |