public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: sys-kernel/dkms/files/, sys-kernel/dkms/
@ 2023-09-24 13:41 Andrew Ammerlaan
  0 siblings, 0 replies; only message in thread
From: Andrew Ammerlaan @ 2023-09-24 13:41 UTC (permalink / raw
  To: gentoo-commits

commit:     1b67dc96dc6cfd8bae66f406075fdf33691b591f
Author:     Andrew Ammerlaan <andrewammerlaan <AT> gentoo <DOT> org>
AuthorDate: Sun Sep 24 13:37:25 2023 +0000
Commit:     Andrew Ammerlaan <andrewammerlaan <AT> gentoo <DOT> org>
CommitDate: Sun Sep 24 13:40:46 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1b67dc96

sys-kernel/dkms: new package, add 3.0.12

The usefulness of dkms for gentoo is arguably limited. But this is in several
overlays now already. I personally need it for ::natinst so I have to maintain
this anyway. Might as well maintain it here to avoid duplicate work in other
overlays. With this release it now properly works with kernel-install and
therefore should now work properly with our eclasses and manually configured
kernels.

Closes: https://bugs.gentoo.org/894300
Closes: https://bugs.gentoo.org/100754
Signed-off-by: Andrew Ammerlaan <andrewammerlaan <AT> gentoo.org>

 sys-kernel/dkms/Manifest                           |  1 +
 sys-kernel/dkms/dkms-3.0.12.ebuild                 | 51 ++++++++++++++++++++++
 .../dkms/files/dkms-3.0.12-add-gentoo-os-id.patch  | 13 ++++++
 sys-kernel/dkms/metadata.xml                       | 18 ++++++++
 4 files changed, 83 insertions(+)

diff --git a/sys-kernel/dkms/Manifest b/sys-kernel/dkms/Manifest
new file mode 100644
index 000000000000..f1d2fef88628
--- /dev/null
+++ b/sys-kernel/dkms/Manifest
@@ -0,0 +1 @@
+DIST dkms-3.0.12.tar.gz 88241 BLAKE2B 672105074b7899080a2468d347e1fdd60bb6be92852746bccff69565b4f49631568764d265495610d3aebf8df1e0c717daa123d6c3be8752d417ed1c633942e0 SHA512 81646f39c458039958159f519d4dcdfb5dcaa303f7c9898310d13e36c38f30ce57efcc2f2fc98a18ec3d232fd3c50e7a2d859ee42a023e62475e7dad070029d7

diff --git a/sys-kernel/dkms/dkms-3.0.12.ebuild b/sys-kernel/dkms/dkms-3.0.12.ebuild
new file mode 100644
index 000000000000..376784e0a285
--- /dev/null
+++ b/sys-kernel/dkms/dkms-3.0.12.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit linux-info
+
+DESCRIPTION="Dynamic Kernel Module Support"
+HOMEPAGE="https://github.com/dell/dkms"
+SRC_URI="https://github.com/dell/dkms/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~x86"
+SLOT="0"
+
+IUSE="systemd"
+
+CONFIG_CHECK="~MODULES"
+
+RDEPEND="
+	sys-apps/kmod
+	virtual/linux-sources
+	systemd? ( sys-apps/systemd )
+"
+
+PATCHES=(
+	"${FILESDIR}/${P}-add-gentoo-os-id.patch"
+)
+
+# Can not work in the emerge sandbox
+RESTRICT="test"
+
+src_compile() {
+	# Nothing to do here
+	return
+}
+
+src_test() {
+	chmod +x dkms || die
+	PATH="${PATH}:$(pwd)" ./run_test.sh || die "Tests failed"
+}
+
+src_install() {
+	if use systemd; then
+		emake install-redhat DESTDIR="${ED}" KCONF="/usr/lib/kernel"
+	else
+		emake install DESTDIR="${ED}" KCONF="/usr/lib/kernel"
+	fi
+	einstalldocs
+	keepdir /var/lib/dkms
+}

diff --git a/sys-kernel/dkms/files/dkms-3.0.12-add-gentoo-os-id.patch b/sys-kernel/dkms/files/dkms-3.0.12-add-gentoo-os-id.patch
new file mode 100644
index 000000000000..10bbacd4fdae
--- /dev/null
+++ b/sys-kernel/dkms/files/dkms-3.0.12-add-gentoo-os-id.patch
@@ -0,0 +1,13 @@
+diff --git a/run_test.sh b/run_test.sh
+index 4cda255..af089cb 100755
+--- a/run_test.sh
++++ b/run_test.sh
+@@ -245,7 +245,7 @@ case "${os_id}" in
+     arch | debian | ubuntu)
+         expected_dest_loc=updates/dkms
+         ;;
+-    alpine)
++    alpine | gentoo)
+         expected_dest_loc=kernel/extra
+         mod_compression_ext=.gz
+         ;;

diff --git a/sys-kernel/dkms/metadata.xml b/sys-kernel/dkms/metadata.xml
new file mode 100644
index 000000000000..bfebb6f1a8ba
--- /dev/null
+++ b/sys-kernel/dkms/metadata.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+	<maintainer type="person">
+		<email>andrewammerlaan@gentoo.org</email>
+		<name>Andrew Ammerlaan</name>
+	</maintainer>
+	<longdescription lang="en">
+		Dynamic Kernel Module Support (DKMS) is a program/framework that enables generating Linux kernel modules whose sources generally reside outside the kernel source tree. The concept is to have DKMS modules automatically rebuilt when a new kernel is installed.
+		An essential feature of DKMS is that it automatically recompiles all DKMS modules if a new kernel version is installed. This allows drivers and devices outside of the mainline kernel to continue working after a Linux kernel upgrade.
+		Another benefit of DKMS is that it allows the installation of a new driver on an existing system, running an arbitrary kernel version, without any need for manual compilation or precompiled packages provided by the vendor.
+		DKMS was written by the Linux Engineering Team at Dell in 2003. It is included in many distributions, such as Ubuntu, Debian, Fedora, SUSE, and Arch. DKMS is free software released under the terms of the GNU General Public License (GPL) v2 or later.
+		DKMS supports both the rpm and deb package formats out-of-the-box.
+	</longdescription>
+	<upstream>
+		<remote-id type="github">dell/dkms</remote-id>
+	</upstream>
+</pkgmetadata>


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

only message in thread, other threads:[~2023-09-24 13:41 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-24 13:41 [gentoo-commits] repo/gentoo:master commit in: sys-kernel/dkms/files/, sys-kernel/dkms/ Andrew Ammerlaan

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