Diff libcap-ng-0.8.5 with a libcap-ng-0.9.3

/usr/portage/sys-libs/libcap-ng/libcap-ng-0.9.3.ebuild 2026-04-24 12:17:44.283405213 +0300
10 10

  
11 11
DESCRIPTION="POSIX 1003.1e capabilities"
12 12
HOMEPAGE="https://people.redhat.com/sgrubb/libcap-ng/"
13
SRC_URI="https://people.redhat.com/sgrubb/${PN}/${P}.tar.gz"
13
SRC_URI="https://github.com/stevegrubb/libcap-ng/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
14 14

  
15 15
LICENSE="GPL-2+ LGPL-2.1+"
16 16
SLOT="0"
17
KEYWORDS="~alpha amd64 arm arm64 ~hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 ~sparc x86"
18
IUSE="python static-libs"
17
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
18
IUSE="bpf deprecated python static-libs"
19 19
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
20 20

  
21
RDEPEND="python? ( ${PYTHON_DEPS} )"
21
RDEPEND="
22
	bpf? (
23
		dev-libs/libbpf:=
24
		sys-process/audit
25
	)
26
	python? ( ${PYTHON_DEPS} )
27
"
22 28
DEPEND="
23 29
	${RDEPEND}
24 30
	sys-kernel/linux-headers
31
	bpf? ( dev-util/bpftool )
32
"
33
BDEPEND="
34
	bpf? (
35
		llvm-core/clang[llvm_targets_BPF(-)]
36
		virtual/pkgconfig
37
	)
38
	python? ( >=dev-lang/swig-2 )
25 39
"
26
BDEPEND="python? ( >=dev-lang/swig-2 )"
27 40

  
28 41
PATCHES=(
29
	"${FILESDIR}"/${P}-python.patch
42
	"${FILESDIR}"/${PN}-0.9.3-audit-out-of-source-build.patch
30 43
)
31 44

  
45
pkg_pretend() {
46
	# bug 972898
47
	if use bpf && [[ ${MERGE_TYPE} != binary ]] ; then
48
		if [[ ! -f /sys/kernel/btf/vmlinux ]] ; then
49
			local err="Cannot read /sys/kernel/btf/vmlinux, which is required by bpftool.\n"
50
			err+="  Typically this means that your kernel is missing the DEBUG_INFO_BTF option,\n"
51
			err+="  without which BPF cannot work. Please build with USE=-bpf or reconfigure your kernel."
52
			die "${err}"
53
		fi
54
	fi
55
}
56

  
32 57
src_prepare() {
33 58
	default
34 59

  
......
44 69
	local ECONF_SOURCE="${S}"
45 70

  
46 71
	local myconf=(
72
		$(use_enable bpf cap-audit)
73
		$(use_enable deprecated)
47 74
		$(use_enable static-libs static)
48 75
		--with-capability_header="${ESYSROOT}"/usr/include/linux/capability.h
49 76
	)
Thank you!