public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: app-antivirus/lkrg/, profiles/
@ 2025-03-02 19:28 John Helmert III
  0 siblings, 0 replies; only message in thread
From: John Helmert III @ 2025-03-02 19:28 UTC (permalink / raw
  To: gentoo-commits

commit:     2aefaab842883f228a1149a8c69deb47202c0c9c
Author:     John Helmert III <ajak <AT> gentoo <DOT> org>
AuthorDate: Sun Mar  2 19:24:23 2025 +0000
Commit:     John Helmert III <ajak <AT> gentoo <DOT> org>
CommitDate: Sun Mar  2 19:25:59 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2aefaab8

app-antivirus/lkrg: add 0.9.9

Masked for now while dealing with a seeming upstream problem.

Bug: https://bugs.gentoo.org/941424
Signed-off-by: John Helmert III <ajak <AT> gentoo.org>

 app-antivirus/lkrg/Manifest          |  2 ++
 app-antivirus/lkrg/lkrg-0.9.9.ebuild | 60 ++++++++++++++++++++++++++++++++++++
 profiles/package.mask                |  5 +++
 3 files changed, 67 insertions(+)

diff --git a/app-antivirus/lkrg/Manifest b/app-antivirus/lkrg/Manifest
index f91deecaf2c2..529a32884f38 100644
--- a/app-antivirus/lkrg/Manifest
+++ b/app-antivirus/lkrg/Manifest
@@ -1,2 +1,4 @@
 DIST lkrg-0.9.8.tar.gz 160156 BLAKE2B 6d07527b5c5b2bddd480a49090a4e4d448e37398c24aeda6bb4d21994f5fe6c2787538cb20d57ac57d38668c2b23b58a3502c96be2e65641fbee596f0d0ec2ca SHA512 86d08f0c0168244ea48fb510e20356f24d8134c96b53b454dc22e7a67fe513b6b57ef946a28288f917f4deca59bcc073401ee2e71d46dad4e634a12c60fe5371
 DIST lkrg-0.9.8.tar.gz.sign 801 BLAKE2B 7c205f33954a18aa7a405533f5541a0f7a0fbcc02502fcd05a7bead20b6f5028ec8c582fc539904a91f6c5faae46ac2fb4633f5be93e6a5535ea2cfd28918146 SHA512 577c183d4f7912351f86cf121494a690ce0f40b6cf16c64b9e28dbd5fb127f7461d9602619b53e3117cb820689e2b09f020ecdfc54a799ba8bbd1bc082024c5c
+DIST lkrg-0.9.9.tar.gz 161522 BLAKE2B da2c3a17f19726f6edec6e01612a9a514d3bf1c0e65a829a48af6175fd971c09d957df269389282d683f831abb37aa9728f7d4df54da9faab228e428303bf572 SHA512 165592b74b8d846fc3c04ece68721c09c7b64b8d056ad2dfa0eec3b544d4a86bba7025f5be2f1ec7ee805411672ec1c830f84da71e5b5adb9ac569226fc1a79f
+DIST lkrg-0.9.9.tar.gz.sign 801 BLAKE2B 69e50a5932c4ea66406f4c8a729a563ffee2a7035b12ee110d500c34a99c66cf32581f9047caaa8f46d9836348e77ffd528cdd9b9920c75628d1584c91b02804 SHA512 3b4d947faf9715f77fb9b8284b850720b8932b38e3ac1ec20094cea9981e35ca9d3c0e3b00893e0eee62a73a9e70b0c5ec05f5fe4eda6a48f1769cd2bba4966e

diff --git a/app-antivirus/lkrg/lkrg-0.9.9.ebuild b/app-antivirus/lkrg/lkrg-0.9.9.ebuild
new file mode 100644
index 000000000000..43b47939edd0
--- /dev/null
+++ b/app-antivirus/lkrg/lkrg-0.9.9.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit linux-mod-r1 systemd verify-sig
+
+DESCRIPTION="Linux Kernel Runtime Guard"
+HOMEPAGE="https://lkrg.org"
+SRC_URI="https://lkrg.org/download/${P}.tar.gz
+	verify-sig? ( https://lkrg.org/download/${P}.tar.gz.sign )"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64"
+
+BDEPEND="verify-sig? ( sec-keys/openpgp-keys-openwall )"
+
+# MODULE_NAMES="lkrg(misc:${S}:${S})"
+VERIFY_SIG_OPENPGP_KEY_PATH="/usr/share/openpgp-keys/openwall.asc"
+
+PATCHES=( "${FILESDIR}/${PN}-0.9.4-gentoo-paths.patch" )
+
+pkg_setup() {
+	CONFIG_CHECK="HAVE_KRETPROBES KALLSYMS_ALL KPROBES JUMP_LABEL"
+	CONFIG_CHECK+=" MODULE_UNLOAD !PREEMPT_RT ~STACKTRACE"
+	linux-mod-r1_pkg_setup
+}
+
+src_unpack() {
+	if use verify-sig; then
+		verify-sig_verify_detached "${DISTDIR}"/${P}.tar.gz{,.sign}
+	fi
+
+	default
+}
+
+src_compile() {
+	local modlist=( lkrg )
+	local modargs=(
+		P_KVER="${KV_FULL}"
+		P_KERNEL="${KERNEL_DIR}"
+	)
+	linux-mod-r1_src_compile
+
+	emake LDFLAGS="${LDFLAGS}" CFLAGS="${CFLAGS}" -C logger
+}
+
+src_install() {
+	# logger target not included by all
+	emake PREFIX="${EPREFIX}/usr" DESTDIR="${ED}" -C logger install
+
+	linux-mod-r1_src_install
+
+	systemd_dounit scripts/bootup/systemd/lkrg.service
+	newinitd scripts/bootup/openrc/lkrg lkrg.initd
+
+	insinto /lib/sysctl.d
+	newins scripts/bootup/lkrg.conf 01-lkrg.conf
+}

diff --git a/profiles/package.mask b/profiles/package.mask
index 1034411f7071..e9a5ca50f0a6 100644
--- a/profiles/package.mask
+++ b/profiles/package.mask
@@ -33,6 +33,11 @@
 
 #--- END OF EXAMPLES ---
 
+# John Helmert III <ajak@gentoo.org> (2025-03-02)
+# Doesn't seem to cleanly load, see:
+# https://github.com/lkrg-org/lkrg/issues/364
+=app-antivirus/lkrg-0.9.9
+
 # Andreas Sturmlechner <asturm@gentoo.org> (2025-03-01)
 # Last release 14 years ago, dead upstream, depends on Qt5 (and even that
 # only by means of downstream patching). Bug #947634.


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2025-03-02 19:29 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-02 19:28 [gentoo-commits] repo/gentoo:master commit in: app-antivirus/lkrg/, profiles/ John Helmert III

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox