Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 1 | SUMMARY = "Inspect and manipulate eBPF programs and maps" |
| 2 | DESCRIPTION = "bpftool is a kernel tool for inspection and simple manipulation \ |
| 3 | of eBPF programs and maps." |
| 4 | LICENSE = "GPLv2" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 5 | DEPENDS = "binutils elfutils" |
| 6 | PROVIDES = "virtual/bpftool" |
| 7 | |
| 8 | inherit bash-completion kernelsrc kernel-arch |
| 9 | |
| 10 | do_populate_lic[depends] += "virtual/kernel:do_patch" |
| 11 | |
Brad Bishop | 0f291cc | 2019-09-01 15:16:57 -0400 | [diff] [blame] | 12 | EXTRA_OEMAKE = "V=1 -C ${S}/tools/bpf/bpftool O=${B} CROSS=${TARGET_PREFIX} CC="${CC}" LD="${LD}" AR=${AR} ARCH=${ARCH}" |
| 13 | |
| 14 | SECURITY_CFLAGS = "" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 15 | |
| 16 | do_configure[depends] += "virtual/kernel:do_shared_workdir" |
| 17 | |
Andrew Geissler | 1548c07 | 2019-02-22 16:03:50 -0600 | [diff] [blame] | 18 | COMPATIBLE_HOST_libc-musl = 'null' |
| 19 | |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 20 | do_compile() { |
| 21 | oe_runmake |
| 22 | } |
| 23 | |
| 24 | do_install() { |
| 25 | oe_runmake DESTDIR=${D} install |
| 26 | } |
| 27 | |
| 28 | PACKAGE_ARCH = "${MACHINE_ARCH}" |
| 29 | |
| 30 | python do_package_prepend() { |
Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 31 | d.setVar('PKGV', d.getVar("KERNEL_VERSION").split("-")[0]) |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 32 | } |
| 33 | |
| 34 | B = "${WORKDIR}/${BPN}-${PV}" |
Andrew Geissler | eafcbb8 | 2020-06-05 17:59:17 -0500 | [diff] [blame] | 35 | PNBLACKLIST[bpftool] ?= "Needs forward porting to kernel 5.2+" |