From 3b9e04461a352ae15ad73805327590e34b7c9556 Mon Sep 17 00:00:00 2001 From: Ronald Farrer Date: Fri, 21 Apr 2023 12:29:08 -0700 Subject: [PATCH] New version and fixed existing git ebuild. --- media-libs/libcamera/libcamera-0.0.4.ebuild | 64 +++++++++++++++++++++ media-libs/libcamera/libcamera-9999.ebuild | 58 +++++++++++++++---- 2 files changed, 111 insertions(+), 11 deletions(-) create mode 100644 media-libs/libcamera/libcamera-0.0.4.ebuild diff --git a/media-libs/libcamera/libcamera-0.0.4.ebuild b/media-libs/libcamera/libcamera-0.0.4.ebuild new file mode 100644 index 0000000..220a258 --- /dev/null +++ b/media-libs/libcamera/libcamera-0.0.4.ebuild @@ -0,0 +1,64 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit meson + +DESCRIPTION="A library for camera support in Linux, Android, and ChromeOS" +HOMEPAGE="https://libcamera.org/" +SRC_URI="https://github.com/${PN}-org/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="LGPL-2.1+" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="doc gstreamer qcam test v4l2 uvcvideo ipu3" + +RESTRICT="!test? ( test )" + +DEPEND=" + dev-libs/libevent + dev-libs/libyaml + media-libs/libepoxy + virtual/libudev + v4l2? ( media-libs/libv4l ) + gstreamer? ( media-libs/gstreamer:1.0 ) + dev-lang/python + dev-python/pyyaml + dev-python/ply + dev-python/jinja + qcam? ( dev-qt/qtcore:5 dev-qt/qtwidgets:5 ) +" +RDEPEND="${DEPEND}" + +BDEPEND=" + virtual/pkgconfig + doc? ( app-doc/doxygen ) + test? ( dev-util/gtest ) +" + +src_configure() { + local emesonargs=( + -Dv4l2=$(usex v4l2 true false) + -Dgstreamer=$(usex gstreamer enabled disabled) + -Dqcam=$(usex qcam enabled disabled) + -Dtest=$(usex test true false) + -Ddocumentation=$(usex doc enabled disabled) + ) + if use uvcvideo || use ipu3; then + local pipelines="" + use uvcvideo && pipelines+="uvcvideo" + use ipu3 && pipelines+=",ipu3" + emesonargs+=(-Dpipelines="${pipelines}") + fi + meson_src_configure +} + +src_compile() { + meson_src_compile +} + +src_install() { + meson_src_install +} + diff --git a/media-libs/libcamera/libcamera-9999.ebuild b/media-libs/libcamera/libcamera-9999.ebuild index a895455..6ce864e 100644 --- a/media-libs/libcamera/libcamera-9999.ebuild +++ b/media-libs/libcamera/libcamera-9999.ebuild @@ -1,28 +1,64 @@ -# Copyright 2021 Gentoo Authors +# Copyright 1999-2023 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 inherit git-r3 meson -DESCRIPTION="A complex camera support library for Linux, Android, and ChromeOS" +DESCRIPTION="A library for camera support in Linux, Android, and ChromeOS" HOMEPAGE="https://libcamera.org/" -EGIT_REPO_URI="git://linuxtv.org/libcamera.git" +EGIT_REPO_URI="https://git.libcamera.org/libcamera/libcamera.git" -LICENSE="LGPL" +LICENSE="LGPL-2.1+" SLOT="0" -KEYWORDS="~x86 ~amd64" -IUSE="v4l2" +KEYWORDS="~amd64 ~x86" +IUSE="doc gstreamer qcam test v4l2 uvcvideo ipu3" -DEPEND="dev-python/yaml and dev-python/ply" +RESTRICT="!test? ( test )" + +DEPEND=" + dev-libs/libevent + dev-libs/libyaml + media-libs/libepoxy + virtual/libudev + v4l2? ( media-libs/libv4l ) + gstreamer? ( media-libs/gstreamer:1.0 ) + dev-lang/python + dev-python/pyyaml + dev-python/ply + dev-python/jinja + qcam? ( dev-qt/qtcore:5 dev-qt/qtwidgets:5 ) +" RDEPEND="${DEPEND}" -BDEPEND="${DEPEND}" + +BDEPEND=" + virtual/pkgconfig + doc? ( app-doc/doxygen ) + test? ( dev-util/gtest ) +" src_configure() { local emesonargs=( - $(meson_use v4l2) - ) - meson_src_configure "-Dpipelines=uvcvideo,ipu3" + -Dv4l2=$(usex v4l2 true false) + -Dgstreamer=$(usex gstreamer enabled disabled) + -Dqcam=$(usex qcam enabled disabled) + -Dtest=$(usex test true false) + -Ddocumentation=$(usex doc enabled disabled) + ) + if use uvcvideo || use ipu3; then + local pipelines="" + use uvcvideo && pipelines+="uvcvideo" + use ipu3 && pipelines+=",ipu3" + emesonargs+=(-Dpipelines="${pipelines}") + fi + meson_src_configure } +src_compile() { + meson_src_compile +} + +src_install() { + meson_src_install +}