dev-util/bpftool: Sync with Gentoo

It's from Gentoo commit c85a2108c082e6122fec344ed997fdbdfd9a2740.

Signed-off-by: Flatcar Buildbot <buildbot@flatcar-linux.org>
This commit is contained in:
Flatcar Buildbot 2026-01-12 07:12:20 +00:00 committed by Krzesimir Nowak
parent ebd37eabeb
commit 7f8fe119ff
2 changed files with 10 additions and 4 deletions

View File

@ -3,7 +3,7 @@
EAPI=8
LLVM_COMPAT=( {15..20} )
LLVM_COMPAT=( {15..21} )
LLVM_OPTIONAL=1
PYTHON_COMPAT=( python3_{11..14} )
@ -86,7 +86,10 @@ src_prepare() {
sed -i -e 's/-Werror//g' src/Makefile.feature || die
# remove hardcoded/unhelpful flags from bpftool
sed -i -e '/CFLAGS += -O2/d' -e 's/-W //g' -e 's/-Wextra //g' src/Makefile || die
sed -e '/CFLAGS += -O2$/d' \
-e '/CFLAGS += -W$/d' \
-e '/CFLAGS += -Wextra$/d' \
-i src/Makefile || die
# always build bpf bits with std=gnu11 for kernel compatibility (bug 955156)
sed -i 's/-fno-stack-protector/& -std=gnu11/g' src/Makefile || die

View File

@ -3,7 +3,7 @@
EAPI=8
LLVM_COMPAT=( {15..20} )
LLVM_COMPAT=( {15..21} )
LLVM_OPTIONAL=1
PYTHON_COMPAT=( python3_{11..14} )
@ -86,7 +86,10 @@ src_prepare() {
sed -i -e 's/-Werror//g' src/Makefile.feature || die
# remove hardcoded/unhelpful flags from bpftool
sed -i -e '/CFLAGS += -O2/d' -e 's/-W //g' -e 's/-Wextra //g' src/Makefile || die
sed -e '/CFLAGS += -O2$/d' \
-e '/CFLAGS += -W$/d' \
-e '/CFLAGS += -Wextra$/d' \
-i src/Makefile || die
# always build bpf bits with std=gnu11 for kernel compatibility (bug 955156)
sed -i 's/-fno-stack-protector/& -std=gnu11/g' src/Makefile || die