Most host gcc doesn't support -fcanon-prefix-map right now, so
empty DEBUG_PREFIX_MAP_EXTRA to fix the below build error.
| gcc: error: unrecognized command-line option ‘-fcanon-prefix-map’; did you mean ‘-fmacro-prefix-map=’?
Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
build uses prepared sourcedir for kernel and relying
on target kernel recipe to prepare this is not the correct
thing for native package. Since the kernel will need target
dependencies cross-compiler etc. to build/prepare the kernel sourcedir
This issue is revealed when bpftool-native is built for riscv64
it ends up in build errors
ERROR: bpftool-native-1.0-r0 do_configure: The sstate manifest for task 'linux-libc-headers:populate_sysroot' (multilib variant '') could not be found.
The pkgarchs considered were: qemuriscv64, allarch, x86_64_x86_64-nativesdk.
But none of these manifests exists:
/mnt/b/yoe/master/sources/poky/build/tmp/sstate-control/manifest-qemuriscv64-linux-libc-headers.populate_sysroot
/mnt/b/yoe/master/sources/poky/build/tmp/sstate-control/manifest-allarch-linux-libc-headers.populate_sysroot
/mnt/b/yoe/master/sources/poky/build/tmp/sstate-control/manifest-x86_64_x86_64-nativesdk-linux-libc-headers.populate_sysroot
ERROR: Logfile of failure stored in: /mnt/b/yoe/master/sources/poky/build/tmp/work/x86_64-linux/bpftool-native/1.0/temp/log.do_configure.2509356
Therefore separate it out into independent recipe and use latest stable
kernel to build it.
Enable musl builds as well for bpftool, it works now.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
When build host machine is not installed with elfutils-libelf-devel, it
throws compile error "libelf.h: No such file or directory". Fix missing
headers file by including path ${STAGING_INCDIR_NATIVE} via CFLAGS variable.
Use headers file from ${STAGING_INCDIR_NATIVE} instead of host machine.
Error:
| libbpf_internal.h:19:10: fatal error: libelf.h: No such file or directory
Signed-off-by: Preeti Sachan <preeti.sachan@intel.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
bpftool is supported for riscv64 and tested on qemuriscv64.
Signed-off-by: Harish Sadineni <Harish.Sadineni@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
There are issues with nativesdk variant
...
ERROR: nativesdk-bpftool-1.0-r0 do_package: QA Issue:
nativesdk-bpftool: Files/directories were installed but not shipped in any package:
/usr/local/oe-sdk-hardcoded-buildpath/sysroots/x86_64-xesdk-linux/usr/sbin/bpftool
/usr/share/bash-completion/completions/bpftool
...
nativesdk.bbclass sets sbindir = "${bindir}" but bpftool is installed under sbin
to fix that add sbin to FILES
for bpftool completions {prefix} is not used but it seems that bitbake expects that
installed files should be perfixed with "${SDKPATHNATIVE}${prefix_nativesdk}"
to fix that override bash_compdir
Signed-off-by: Denys Zagorui <dzagorui@cisco.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
When the externalsrc class is used the tasks listed in
SRCTREECOVEREDTASKS are deleted to prevent them being executed. If
externalsrc is used for the kernel then this will include
virtual/kernel:do_patch.
We can depend on do_shared_workdir instead as this will survive when
externalsrc is used.
Similar to [openembedded-core] (eab605bab945 "perf: Fix externalsrc support")
Signed-off-by: Denys Zagorui <dzagorui@cisco.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
This is the result of automated script (0.9.1) conversion:
oe-core/scripts/contrib/convert-overrides.py .
converting the metadata to use ":" as the override character instead of "_".
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Pass -f(debug|macro)-prefix-map through CC because libbpf
build system overrides CFLAGS. Also remap STAGING_KERNEL_DIR
because it is also stored in resulting executable
Signed-off-by: Denys Zagorui <dzagorui@cisco.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Have not seen build issues for 5.4 and 5.10
x86-64 kernels so allow to build it
Signed-off-by: Denys Zagorui <dzagorui@cisco.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Make sure PNBLACKLIST assignments in recipe files use weak assignment,
so they can be overridden in, for example, local.conf files.
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
We do not pass CFLAGS to build and fortify sources needs some
optimization to be enabled, its better to reset the additional flags and
let the build system add them as it needs
Fixes build failures like
tools/include/tools/libc_compat.h:11:21: error: static declaration of 'reallocarray' follows non-static declaration
| 11 | static inline void *reallocarray(void *ptr, size_t nmemb, size_t size)
| | ^~~~~~~~~~~~
Signed-off-by: Khem Raj <raj.khem@gmail.com>
bpftool is a 'special' recipe since it does "inherit kernelsrc", like
perf in oe-core or cpupower in meta-oe.
they don't have their own sources, but reuse the kernel source tree,
from virtual/kernel recipe. As such, checking the license file does
not seem relevant, since the fetching (and license check) is deferred
to the virtual/kernel recipe.
Remove LIC_FILES_CHKSUM like it is done in perf and cpupower.
Signed-off-by: Nicolas Dechesne <nicolas.dechesne@linaro.org>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
A couple have still been missed in the past despite multiple
attempts at doing so (or simply have re-appeared?).
Search & replace made using the following command:
sed -e 's|\(d\.getVar \?\)( \?\([^,()]*\), \?True)|\1(\2)|g' \
-i $(git grep -E 'getVar ?\( ?([^,()]*), ?True\)' \
| cut -d':' -f1 \
| sort -u)
Signed-off-by: André Draszik <andre.draszik@jci.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
The bpftool allows for inspection and simple manipulation of
eBPF programs and maps, so common in the kernel selftests.
Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org>
Signed-off-by: Khem Raj <raj.khem@gmail.com>