package created using the webbuild interface [release 0.12.7-1mamba;Sat Feb 24 2024]

This commit is contained in:
Silvan Calarco 2024-02-26 00:05:48 +01:00
parent 1e18512a49
commit 3bc2964562
3 changed files with 92 additions and 0 deletions

View File

@ -1,2 +1,4 @@
# v4l2loopback-dkms
A kernel module to create V4L2 loopback devices.

View File

@ -0,0 +1,33 @@
From e7edf2f55b7eb71b69984110f3c8e31b8ac6285e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?IOhannes=20m=20zm=C3=B6lnig?=
<zmoelnig@umlautS.umlaeute.mur.at>
Date: Fri, 5 Aug 2022 18:42:22 +0200
Subject: [PATCH] Backported dkms-patch from Ubuntu
Closes: https://github.com/umlaeute/v4l2loopback/issues/498
---
dkms.conf | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/dkms.conf b/dkms.conf
index f697db2b..7d5ed75c 100644
--- a/dkms.conf
+++ b/dkms.conf
@@ -3,8 +3,15 @@ PACKAGE_VERSION="0.12.7"
if [ -f $kernel_source_dir/.config ]; then
. $kernel_source_dir/.config
- if [ "${CONFIG_VIDEO_V4L2:-n}" = "n" ]; then
- BUILD_EXCLUSIVE_KERNEL="REQUIRES CONFIG_VIDEO_V4L2"
+ if ! { echo "$kernelver"; echo 5.18; } | sort -V -C; then
+ # for linux>=5.18, CONFIG_VIDEO_V4L2 has been renamed to CONFIG_VIDEO_DEV
+ if [ "${CONFIG_VIDEO_DEV:-n}" = "n" ]; then
+ BUILD_EXCLUSIVE_KERNEL="REQUIRES CONFIG_VIDEO_DEV"
+ fi
+ else
+ if [ "${CONFIG_VIDEO_V4L2:-n}" = "n" ]; then
+ BUILD_EXCLUSIVE_KERNEL="REQUIRES CONFIG_VIDEO_V4L2"
+ fi
fi
fi

57
v4l2loopback-dkms.spec Normal file
View File

@ -0,0 +1,57 @@
Name: v4l2loopback-dkms
Version: 0.12.7
Release: 1mamba
Summary: A kernel module to create V4L2 loopback devices
Group: System/Kernel and Hardware
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://github.com/umlaeute/v4l2loopback
Source: https://github.com/umlaeute/v4l2loopback.git/v%{version}/v4l2loopback-%{version}.tar.bz2
Patch0: v4l2loopback-dkms-0.12.7-kernel-5.18.patch
License: GPL
## AUTOBUILDREQ-BEGIN
## AUTOBUILDREQ-END
Requires(post):dkms
%description
A kernel module to create V4L2 loopback devices.
%prep
%setup -q -n v4l2loopback-%{version}
%patch 0 -p1 -b .kernel-5.18
%build
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
make DESTDIR=%{buildroot} PREFIX=%{_prefix} install-utils install-man
install -D -m0644 v4l2loopback.c v4l2loopback_formats.h dkms.conf Makefile \
-t %{buildroot}%{_prefix}/src/v4l2loopback-%{version}
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%preun
dkms remove -q -m v4l2loopback -v %{version} --all
:
%posttrans
if [ $1 -ge 1 ]; then
dkms add -q -m v4l2loopback -v %{version}
dkms install -q -m v4l2loopback -v %{version} --force
fi
:
%files
%defattr(-,root,root)
%{_bindir}/v4l2loopback-ctl
%dir %{_prefix}/src/v4l2loopback-%{version}
%{_prefix}/src/v4l2loopback-%{version}/*
%{_mandir}/man1/v4l2loopback-ctl.1*
%doc AUTHORS COPYING
%changelog
* Sat Feb 24 2024 Silvan Calarco <silvan.calarco@mambasoft.it> 0.12.7-1mamba
- package created using the webbuild interface