summaryrefslogtreecommitdiff
path: root/dev-util/bcc
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-03-26 01:01:01 +0000
committerV3n3RiX <venerix@koprulu.sector>2024-03-26 01:01:01 +0000
commit970b06af05f42e54a47439caaa9bd9a31ee30142 (patch)
tree7d58838b2008550a4c1d06b306efafa0e4624542 /dev-util/bcc
parentfc68863e718441fe15bb0dea2ca03ea06a6f558d (diff)
gentoo auto-resync : 26:03:2024 - 01:01:01
Diffstat (limited to 'dev-util/bcc')
-rw-r--r--dev-util/bcc/Manifest2
-rw-r--r--dev-util/bcc/bcc-0.30.0.ebuild141
2 files changed, 143 insertions, 0 deletions
diff --git a/dev-util/bcc/Manifest b/dev-util/bcc/Manifest
index 2bc157d428b7..27fd1f36e43f 100644
--- a/dev-util/bcc/Manifest
+++ b/dev-util/bcc/Manifest
@@ -4,7 +4,9 @@ AUX bcc-0.25.0-cmakelists.patch 358 BLAKE2B 0159aa6e483bd5fab0bc920e8416a94a4380
AUX bcc-0.9.0-no-luajit-automagic-dep.patch 463 BLAKE2B 286ed298055cbdb22d9c3f3f064c77da685cf75cc8c0ab0cad4d4b473f0eac0b1533ca8eb7e6159108d184d16db7a264b0ea9d30ccdc3d988d88bab28be7310d SHA512 6e5c20de22547410ffa566cb8226a47ee0e8c91183bc5b70eb22637a08fe55cfc96fde169ef3ab8d6e8d7c9e356c35e61b164b3ad675835d3ea8d5239a448979
DIST bcc-0.28.0.tar.gz 6148954 BLAKE2B cfd3c8d63128e050512462449ff7d467f8f809c239ac01ae8e75365e89116ec351641a68682d23472aa3b4e265547bb20ca5572084c532a40ccd3131edf255a2 SHA512 792ce93dba64b1f87390b2602dcaeba04ac8b2863652b06eb9a907b93bc6137a944b856cc6fa9c7a38671c89814740967561ca4f3b29c267babca7dc5e78aa02
DIST bcc-0.29.1.tar.gz 6778304 BLAKE2B 23df483df59ef7d66117b15628299a32155136aa5254edbf76f7507a972f3ebcba1d4b2aa83c41e8f061eeeb96812f522c34fed27e9a37e5f4ad3478c7cde88f SHA512 9e60130ea602e19e6c6f88a8c17023cea5daf4c5bcc7af8816e9f5c662341136eb449a3fdf870ffad215495ac3bf895115c0d968d92ce79ebe2899b3e2464d24
+DIST bcc-0.30.0.tar.gz 6797246 BLAKE2B 517f4fcce8bcaf4c8c17075f9a906b452ee14a0c46fa500c301521fe46d854fcf4f632e741b34168dfeb819d9b0d64b967e716fa6222ba7dcaeddb03570985e6 SHA512 70478ca8c18e7f106c462513ca9af46f49b4ebcca6380a9393208fca88f83895a7396f918bf5d01dce1bc4a876bccb9b95aa56d426e55d384cf11c9baaa6a89b
EBUILD bcc-0.28.0-r1.ebuild 3077 BLAKE2B 705569eaa9955df0c937fb91e16bf0581efa07f75c320998b0e77965be0d44862c79a858eb1a8741ecc80aede9f628896d60a39562dabb850eeb3d7a59422597 SHA512 6b41066299ee4b0e38688aad3a471df90aef356320e478d150ee5d0e5ea35fdeff601fa68f91f0b14c3b876aac43afd86e6a4269b8eff6cd39b4ecd6acdfa939
EBUILD bcc-0.29.1-r1.ebuild 3076 BLAKE2B 336b061630c512e338f92f29cd2cb83b8445436fcd31ae75008f38a989481725b589d185173ced2ba1e86d75017827a8d4619cd53ff59e45280cab67cb733d6d SHA512 544bf5ec686458b51a2e9dbc18ffb10e08d33c1626cee2698c395fa51b283a0e069fefb94dbb1f15a61406fd515a419024811a8f0de7adef4448281752cc09cc
EBUILD bcc-0.29.1-r2.ebuild 3214 BLAKE2B 2bd87d02bf6a10f467971dd38ce76d83705664026d8b716c36b3ad03f5fa9263aaeef5df0653a661420620b16831c12cc8fce62148469d666d938fa16ed3316b SHA512 a836d324e5a5da246facc5d35546c719e23b0ed0eb1588252e49a146a4b62e83925ef18d7c6a6ceba2327c58fda471f02a615c560978a43c20816b1f3cfcb8a5
+EBUILD bcc-0.30.0.ebuild 3214 BLAKE2B 2bd87d02bf6a10f467971dd38ce76d83705664026d8b716c36b3ad03f5fa9263aaeef5df0653a661420620b16831c12cc8fce62148469d666d938fa16ed3316b SHA512 a836d324e5a5da246facc5d35546c719e23b0ed0eb1588252e49a146a4b62e83925ef18d7c6a6ceba2327c58fda471f02a615c560978a43c20816b1f3cfcb8a5
MISC metadata.xml 419 BLAKE2B 8b46153f6ab2d6959a767f105a9e33109f705bf879bd4d6708eb4a85e310140d8f810569bf3e37f89bd5a07758de7653697214643b606dc314009e8b8db709ac SHA512 3036d51a8ff5c5adc507387aad252ab7a90c341c5f04c626158353d938992e78c6b5e344354220141979f91522e0204e388d47fd0ccf91415634f6cde646a0c3
diff --git a/dev-util/bcc/bcc-0.30.0.ebuild b/dev-util/bcc/bcc-0.30.0.ebuild
new file mode 100644
index 000000000000..236331466a37
--- /dev/null
+++ b/dev-util/bcc/bcc-0.30.0.ebuild
@@ -0,0 +1,141 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+LUA_COMPAT=( luajit )
+PYTHON_COMPAT=( python3_{9..12} )
+LLVM_MAX_SLOT=18
+
+inherit cmake linux-info llvm lua-single python-r1 toolchain-funcs
+
+DESCRIPTION="Tools for BPF-based Linux IO analysis, networking, monitoring, and more"
+HOMEPAGE="https://iovisor.github.io/bcc/"
+SRC_URI="https://github.com/iovisor/bcc/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~riscv ~x86"
+IUSE="+lua test"
+
+REQUIRED_USE="
+ ${PYTHON_REQUIRED_USE}
+ lua? ( ${LUA_REQUIRED_USE} )
+"
+
+# tests need root access
+RESTRICT="test"
+
+RDEPEND="
+ >=dev-libs/elfutils-0.166:=
+ >=dev-libs/libbpf-1.2.0:=[static-libs(-)]
+ sys-kernel/linux-headers
+ <sys-devel/clang-$((${LLVM_MAX_SLOT} + 1)):=
+ <sys-devel/llvm-$((${LLVM_MAX_SLOT} + 1)):=[llvm_targets_BPF(+)]
+ ${PYTHON_DEPS}
+ lua? ( ${LUA_DEPS} )
+"
+DEPEND="
+ ${RDEPEND}
+ test? (
+ || (
+ net-misc/iputils[arping]
+ net-analyzer/arping
+ )
+ net-analyzer/netperf
+ net-misc/iperf:*
+ )
+"
+BDEPEND="
+ app-arch/zip
+ virtual/pkgconfig
+"
+
+PATCHES=(
+ "${FILESDIR}/bcc-0.9.0-no-luajit-automagic-dep.patch"
+ "${FILESDIR}/bcc-0.25.0-cmakelists.patch"
+ "${FILESDIR}/bcc-0.23.0-man-compress.patch"
+)
+
+pkg_pretend() {
+ local CONFIG_CHECK="~BPF ~BPF_SYSCALL ~NET_CLS_BPF ~NET_ACT_BPF
+ ~HAVE_EBPF_JIT ~BPF_EVENTS ~DEBUG_INFO ~FUNCTION_TRACER ~KALLSYMS_ALL
+ ~KPROBES"
+
+ check_extra_config
+}
+
+pkg_setup() {
+ llvm_pkg_setup
+ python_setup
+}
+
+src_prepare() {
+ local bpf_link_path
+
+ # this avoids bundling
+ bpf_link_path="$(realpath --relative-to="${S}/src/cc/libbpf" /usr/include/bpf)" || die
+ ln -sfn "${bpf_link_path}" src/cc/libbpf/include || die
+
+ # bug 811288
+ local script scriptname
+ for script in $(find tools/old -type f -name "*.py" || die); do
+ scriptname=$(basename ${script} || die)
+ mv ${script} tools/old/old-${scriptname} || die
+ done
+
+ cmake_src_prepare
+}
+
+python_add_impl() {
+ bcc_python_impls+="${EPYTHON};"
+}
+
+src_configure() {
+ local bcc_python_impls
+ python_foreach_impl python_add_impl
+
+ local mycmakeargs=(
+ -DREVISION=${PV%%_*}
+ -DENABLE_LLVM_SHARED=ON
+ -DENABLE_NO_PIE=OFF
+ -DCMAKE_USE_LIBBPF_PACKAGE=ON
+ -DLIBBPF_INCLUDE_DIRS="$($(tc-getPKG_CONFIG) --cflags-only-I libbpf | sed 's:-I::g')"
+ -DKERNEL_INCLUDE_DIRS="${KERNEL_DIR}"
+ -DPYTHON_CMD="${bcc_python_impls%;}"
+ -Wno-dev
+ )
+ if use lua && use lua_single_target_luajit; then
+ mycmakeargs+=( -DWITH_LUAJIT=1 )
+ fi
+
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+ remove_egg_info() { rm -rf "${D}/$(python_get_sitedir)"/*.egg-info || die; }
+ python_foreach_impl remove_egg_info
+
+ python_replicate_script $(grep -Flr '#!/usr/bin/python' "${ED}/usr/share/bcc/tools")
+ python_foreach_impl python_optimize
+
+ newenvd "${FILESDIR}"/60bcc.env 60bcc.env
+ local -A rename_tools=(
+ [trace]=1
+ )
+
+ local tool name
+ for tool in "${ED}"/usr/share/bcc/tools/*; do
+ [[ ! -x ${tool} && ! -L ${tool} || -d ${tool} ]] && continue
+ name=${tool##*/}
+ [[ -n ${rename_tools[${name}]} ]] && name=bcc-${name}
+ dosym -r "${tool#${ED}}" /usr/sbin/${name}
+ done
+
+ docompress /usr/share/${PN}/man
+
+ newenvd - "70${P}" <<-_EOF_
+ MANPATH="${EPREFIX}/usr/share/${PN}/man"
+ _EOF_
+}