summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Ammerlaan <andrewammerlaan@gentoo.org>2023-06-21 11:31:43 +0200
committerAndrew Ammerlaan <andrewammerlaan@gentoo.org>2023-06-21 11:36:09 +0200
commit0129e062287948921ea13e781b87dca9c3a0134a (patch)
treec45f2055d392b0c0f1952e188cddae6c2bada030 /sci-libs
parentdev-perl/Net-SSLeay: Stabilize 1.920.0-r1 ppc, #908923 (diff)
downloadgentoo-0129e062287948921ea13e781b87dca9c3a0134a.tar.gz
gentoo-0129e062287948921ea13e781b87dca9c3a0134a.tar.bz2
gentoo-0129e062287948921ea13e781b87dca9c3a0134a.zip
sci-libs/linux-gpib-modules: migrate to linux-mod-r1.eclass
Upstream has one target for all modules, this doesn't really work with linux-mod(-r1) src_compile so we keep the workaround that was already in the ebuild. Now using MODULES_KERNEL_MIN to check the kernel version, got rid of the custom solution in the ebuild. Call modules_post_process to strip, compress and sign the modules Signed-off-by: Andrew Ammerlaan <andrewammerlaan@gentoo.org>
Diffstat (limited to 'sci-libs')
-rw-r--r--sci-libs/linux-gpib-modules/linux-gpib-modules-4.3.5-r1.ebuild67
1 files changed, 67 insertions, 0 deletions
diff --git a/sci-libs/linux-gpib-modules/linux-gpib-modules-4.3.5-r1.ebuild b/sci-libs/linux-gpib-modules/linux-gpib-modules-4.3.5-r1.ebuild
new file mode 100644
index 000000000000..eae3c0404cb4
--- /dev/null
+++ b/sci-libs/linux-gpib-modules/linux-gpib-modules-4.3.5-r1.ebuild
@@ -0,0 +1,67 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit linux-mod-r1
+
+DESCRIPTION="Kernel modules for GPIB (IEEE 488.2) hardware"
+HOMEPAGE="https://linux-gpib.sourceforge.io/"
+SRC_URI="mirror://sourceforge/linux-gpib/linux-gpib-${PV}.tar.gz"
+S="${WORKDIR}/linux-gpib-kernel-${PV}"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 ~arm ~x86"
+IUSE="debug"
+
+COMMONDEPEND=""
+RDEPEND="${COMMONDEPEND}
+ acct-group/gpib
+"
+DEPEND="${COMMONDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+ # don't fix debian bugs if they break gentoo
+ "${FILESDIR}/${PN}-4.3.4-depmod.patch"
+)
+
+MODULES_KERNEL_MIN=2.6.8
+
+src_unpack() {
+ default
+ unpack "${WORKDIR}/linux-gpib-${PV}/linux-gpib-kernel-${PV}.tar.gz"
+}
+
+src_configure() {
+ my_gpib_makeopts=''
+ use debug && my_gpib_makeopts+='GPIB-DEBUG=1 '
+
+ my_gpib_makeopts+="LINUX_SRCDIR=${KERNEL_DIR} "
+}
+
+src_compile() {
+ set_arch_to_kernel
+
+ # The individual modules don't have separate targets so we can't use
+ # modlist here.
+ emake \
+ ${my_gpib_makeopts}
+}
+
+src_install() {
+ set_arch_to_kernel
+ emake \
+ DESTDIR="${ED}" \
+ INSTALL_MOD_PATH="${ED}" \
+ DEPMOD="/bin/true" \
+ docdir="${ED}/usr/share/doc/${PF}/html" \
+ ${my_gpib_makeopts} \
+ install
+
+ modules_post_process
+
+ dodoc ChangeLog AUTHORS README* NEWS
+ einstalldocs
+}