v4l2-relayd: remove dependency to icamerasrc

This commit is contained in:
betaboon 2023-04-08 15:02:45 +02:00
parent e8a861f940
commit 615c0d9b22
2 changed files with 5 additions and 44 deletions

View File

@ -2,27 +2,14 @@
, stdenv
, fetchgit
, autoreconfHook
, coreutils
, glib
, gnugrep
, gst_all_1
, icamerasrc
, libtool
, makeWrapper
, pkg-config
, which
}:
let
gst = [
gst_all_1.gstreamer.out
gst_all_1.gst-plugins-bad
gst_all_1.gst-plugins-base
gst_all_1.gst-plugins-good
icamerasrc
];
in
stdenv.mkDerivation rec {
pname = "v4l2-relayd-${icamerasrc.ipuVersion}";
pname = "v4l2-relayd";
version = "0.1.3";
src = fetchgit {
@ -38,39 +25,18 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [
autoreconfHook
libtool
makeWrapper
pkg-config
which
];
buildInputs = [
glib
] ++ gst;
gst_all_1.gstreamer
gst_all_1.gst-plugins-base
];
preConfigure = "./autogen.sh --prefix=$out";
postInstall = ''
mkdir -p $out/lib/systemd/system $out/etc/default
cp data/systemd/v4l2-relayd.service $out/lib/systemd/system
cp data/etc/default/v4l2-relayd $out/etc/default
substituteInPlace $out/lib/systemd/system/v4l2-relayd.service \
--replace grep ${gnugrep}/bin/grep \
--replace cut ${coreutils}/bin/cut \
--replace /usr/bin/test ${coreutils}/bin/test \
--replace /usr/bin/v4l2-relayd $out/bin/v4l2-relayd \
--replace /etc/default $out/etc/default \
--replace "DeviceAllow=char-video4linux" ""
substituteInPlace $out/etc/default/v4l2-relayd \
--replace 'FORMAT=YUY2' 'FORMAT=NV12' \
--replace 'CARD_LABEL="Virtual Camera"' 'CARD_LABEL="Intel MIPI Camera"' \
--replace 'VIDEOSRC="videotestsrc"' 'VIDEOSRC="icamerasrc"'
wrapProgram $out/bin/v4l2-relayd \
--prefix GST_PLUGIN_PATH : ${lib.makeSearchPathOutput "lib" "lib/gstreamer-1.0" gst}
'';
meta = with lib; {
description = "Streaming relay for v4l2loopback using GStreamer";
homepage = "https://git.launchpad.net/v4l2-relayd";

View File

@ -27426,12 +27426,7 @@ with pkgs;
v4l-utils = qt5.callPackage ../os-specific/linux/v4l-utils { };
v4l2-relayd-ipu6 = callPackage ../os-specific/linux/v4l2-relayd {
icamerasrc = gst_all_1.icamerasrc-ipu6;
};
v4l2-relayd-ipu6ep = callPackage ../os-specific/linux/v4l2-relayd {
icamerasrc = gst_all_1.icamerasrc-ipu6ep;
};
v4l2-relayd = callPackage ../os-specific/linux/v4l2-relayd { };
vendir = callPackage ../development/tools/vendir { };