Diff scap-driver-0.29.3 with a scap-driver-0.29.3-r4
/usr/portage/dev-util/scap-driver/scap-driver-0.29.3-r4.ebuild 2023-10-09 14:52:31.000368388 +0300 | ||
---|---|---|
3 | 3 | |
4 | 4 |
EAPI=8 |
5 | 5 | |
6 |
inherit cmake linux-mod |
|
6 |
inherit cmake linux-mod-r1 |
|
7 | 7 | |
8 | 8 |
DESCRIPTION="Kernel module for dev-util/sysdig" |
9 | 9 |
HOMEPAGE="https://sysdig.com/" |
... | ... | |
24 | 24 | |
25 | 25 |
CONFIG_CHECK="HAVE_SYSCALL_TRACEPOINTS ~TRACEPOINTS" |
26 | 26 | |
27 |
PATCHES=( "${FILESDIR}"/${PV}-fix-kmod-build-on-5.18+.patch ) |
|
27 |
PATCHES=( |
|
28 |
"${FILESDIR}"/${PV}-fix-kmod-build-on-5.18+.patch |
|
29 |
"${FILESDIR}"/${PV}-fix-kmod-build-on-6.2+.patch |
|
30 |
"${FILESDIR}"/${PV}-fix-kmod-build-on-6.3+.patch |
|
31 |
"${FILESDIR}"/${PV}-fix-kmod-build-on-6.4+.patch |
|
32 |
) |
|
28 | 33 | |
29 | 34 |
src_configure() { |
30 | 35 |
local mycmakeargs=( |
... | ... | |
36 | 41 |
) |
37 | 42 | |
38 | 43 |
cmake_src_configure |
44 |
} |
|
39 | 45 | |
40 |
# setup linux-mod ugliness |
|
41 |
MODULE_NAMES="scap(extra:${BUILD_DIR}/driver/src:)" |
|
42 |
BUILD_PARAMS='KERNELDIR="${KERNEL_DIR}"' |
|
43 |
# work with clang-built kernels (#816024) |
|
44 |
if linux_chkconfig_present CC_IS_CLANG; then |
|
45 |
BUILD_PARAMS+=' CC=${CHOST}-clang' |
|
46 |
if linux_chkconfig_present LD_IS_LLD; then |
|
47 |
BUILD_PARAMS+=' LD=ld.lld' |
|
48 |
if linux_chkconfig_present LTO_CLANG_THIN; then |
|
49 |
# kernel enables cache by default leading to sandbox violations |
|
50 |
BUILD_PARAMS+=' ldflags-y=--thinlto-cache-dir= LDFLAGS_MODULE=--thinlto-cache-dir=' |
|
51 |
fi |
|
52 |
fi |
|
53 |
fi |
|
46 |
src_compile() { |
|
47 |
local modlist=( scap=:"${BUILD_DIR}"/driver/src ) |
|
48 |
local modargs=( KERNELDIR="${KV_OUT_DIR}" ) |
|
54 | 49 | |
55 |
BUILD_TARGETS="all" |
|
50 |
linux-mod-r1_src_compile |
|
56 | 51 |
} |