From a531a0d5810ec8a644c100d358a421fdf1eaaf96 Mon Sep 17 00:00:00 2001 From: EnumDev Date: Fri, 4 Sep 2026 16:00:15 +0300 Subject: [PATCH] Initial commit --- .gitignore | 3 +++ check-version.sh | 15 +++++++++++++++ info.yml | 33 +++++++++++++++++++++++++++++++++ recipe.sh | 19 +++++++++++++++++++ 4 files changed, 70 insertions(+) create mode 100644 .gitignore create mode 100644 check-version.sh create mode 100644 info.yml create mode 100644 recipe.sh diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9d96df7 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +# Ignore BPM archives and signatures +*.bpm +*.bpm.sig diff --git a/check-version.sh b/check-version.sh new file mode 100644 index 0000000..9a2b2e0 --- /dev/null +++ b/check-version.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +# Git repository +REPO="https://git.linuxtv.org/v4l-utils.git" + +# Get tag name using 'git ls-remote' +TAG_NAME=$(git ls-remote --exit-code --refs --tags --sort='v:refname' "$REPO" | tail -1 | cut -d'/' -f3) + +# Get version number from tag name +VERSION=$(echo "$TAG_NAME" | rev | cut -d'-' -f1 | rev) + +# Trim 'v' character in VERSION variable +VERSION=$(echo "$VERSION" | tr -d 'v') + +echo "$VERSION" diff --git a/info.yml b/info.yml new file mode 100644 index 0000000..b140de2 --- /dev/null +++ b/info.yml @@ -0,0 +1,33 @@ +name: v4l-utils +description: Userspace tools and conversion library for Video 4 Linux +version: 1.32.0 +revision: 1 +url: https://linuxtv.org/ +license: GPL-2.O-or-later,LGPL-2.1-or-later +maintainers: + - enumdev@enumerated.dev +architecture: any +type: source +depends: + - gcc-libs + - hicolor-icon-theme + - json-c + - libbpf + - libjpeg-turbo + - libudev +optional_depends: + - alsa-lib:For qv4l2 + - qt6-5compat:For qv4l2 + - qt6-base:For qv4l2 and qvidcap +make_depends: + - alsa-lib + - clang + - doxygen + - meson + - qt6-5compat + - qt6-base +downloads: + - url: https://linuxtv.org/downloads/v4l-utils/v4l-utils-${BPM_PKG_VERSION}.tar.xz + extract_to: ${BPM_SOURCE} + extract_strip_components: 1 + checksum: 6828828a17775526eb93fb258a9294d1d1073d633c344dd71ecd4e7a1ffb7dfc diff --git a/recipe.sh b/recipe.sh new file mode 100644 index 0000000..0085cd5 --- /dev/null +++ b/recipe.sh @@ -0,0 +1,19 @@ +# This is the recipe.sh script. It is executed by BPM in a temporary directory when compiling a source package +# BPM Expects the source code to be extracted into the automatically created 'source' directory which can be accessed using $BPM_SOURCE +# BPM Expects the output files to be present in the automatically created 'output' directory which can be accessed using $BPM_OUTPUT + +# The build function is executed in the source directory +# This function is used to compile the source code +build() { + meson setup build --prefix=/usr -Dgconv=disabled + meson compile -C build +} + +# The package function is executed in the source directory +# This function is used to move the compiled files into the output directory +package() { + meson install -C build --destdir="$BPM_OUTPUT" + + # Install package license + install -Dm644 "$BPM_SOURCE"/COPYING* -t "$BPM_OUTPUT"/usr/share/licenses/v4l-utils +}